How to create many properties at the same time using list/arrays I want to create some integer properties using loops just to save time and lines of code. So basically, the new properties should be something like this:

bpy.types.Scene.prop1
bpy.types.Scene.prop2
bpy.types.Scene.prop3
....
....
bpy.types.Scene.prop10


Here is my approach. First, I created a list of desired variables, "prop1...prop10".

prop_name = ["prop%d"%(i+1) for i in range(10)]


Then I use a for loop to create these properties.

for i, name in enumerate(prop_name):
    bpy.types.Scene.name = bpy.props.IntProperty(name="prop %d"%(i+1))


With this, I expect 10 properties. Now I have 2 issue:

The name that should be shown inside the properties is not changing with respect to their index values.

2nd Issue: I'm not actually able to put them in my Panel. So, I guess, there are no properties created with this method.

(&lt;built-in function Intproperty&gt;, {'name':'prop10','attr':'name'})
(&lt;built-in function Intproperty&gt;, {'name':'prop10','attr':'name'})
(&lt;built-in function Intproperty&gt;, {'name':'prop10','attr':'name'})
(&lt;built-in function Intproperty&gt;, {'name':'prop10','attr':'name'})


How can I change this name with index value, or let me know if there is an another way to create multiple properties.
Use the python built in method setattr


  The function assigns the value to the attribute, provided the object allows it. For example, setattr(x, 'foobar', 123) is equivalent to x.foobar = 123.


import bpy
from bpy.props import IntProperty
from bpy.types import Scene

prop_name = ["prop%d" % (i+1) for i in range(10)]

for i, name in enumerate(prop_name):
    setattr(Scene, name, IntProperty(name="prop %d" % (i+1)))


On your code, you are setting the name property of Scene class ten times to an IntProperty.

for i, name in enumerate(prop_name):
    bpy.types.Scene.name = bpy.props.IntProperty(name="prop %d"%(i+1))


is equivalent to

bpy.types.Scene.name = IntProperty(name="prop 1")
bpy.types.Scene.name = IntProperty(name="prop 2")
...
bpy.types.Scene.name = IntProperty(name="prop 10")


This is a double whammy, as Scene already has a StringProperty name.  (eg bpy.data.scenes["NAME"] has "NAME" for a name)  The ID class is a base class for all blender objects in the subclass list. Another clue this is BAD is the blank scene name in UI after running question code.  Click on scene name and it will most likely crash blender.