How to access custom properties from python How can I access a custom property of an object from python, the suggestion Blender gives me if I pass the mouse over the custom properties named "prop",

bpy.data.objects["Cube"].["prop"] 


get me this output in the console 

&gt;&gt;&gt; bpy.data.objects["Cube"].["prop"]
  File "&lt;blender_console&gt;", line 1
    bpy.data.objects["Cube"].["prop"]
                             ^
SyntaxError: invalid syntax
You just need to remove the dot, so the correct invocation is:

bpy.data.objects["Cube"]["prop"]


Python's subscription syntax doesn't use dot character.

Note: In Python terminology this is known as getitem rather then getattr access.