for obj in bpy.data.objects: if obj.type == 'MESH': # Flat shading for poly in obj.data.polygons: poly.use_smooth = False