The first option here is where you specify the beginning and ending range for the FID numbers...
import arcpy
arcpy.env.workspace = "c:/Wing/Sk"
# Set overwrite option
arcpy.env.overwriteOutput = True
# Make a Feature Layer for the original shapefile
arcpy.MakeFeatureLayer_management("spatially50.shp", "lyr_MyOriginalLayer")
# Then create a layer for each FID and export it out
for FID in range(0,49):
arcpy.MakeFeatureLayer_management("lyr_MyOriginalLayer", "lyr_MyIndividualLayer{0}".format(FID), "\"FID\" = {0}".format(FID))
arcpy.CopyFeatures_management("lyr_MyIndividualLayer{0}".format(FID), "zzzShapefileName {0}.shp".format(FID))
print("Created ShapefileName {0}.shp".format(FID))
The second example is if you want to export all the FID's in the shapefile... (then you don't have to change the range...)
import arcpy
arcpy.env.workspace = "c:/Wing/Sk"
# Set overwrite option
arcpy.env.overwriteOutput = True
# Make a Feature Layer for the original shapefile
arcpy.MakeFeatureLayer_management("spatially50.shp", "lyr_MyOriginalLayer")
# Create an empty list to hold the FID numbers
myFIDNumbers = []
# First, loop through the original layer and get all the FID numbers.
with arcpy.da.SearchCursor("lyr_MyOriginalLayer", ["FID"]) as cursor:
for row in cursor:
myFIDNumbers.append(row[0])
# Then create a layer for each FID and export it out
for FID in myFIDNumbers:
arcpy.MakeFeatureLayer_management("lyr_MyOriginalLayer", "lyr_MyIndividualLayer{0}".format(FID), "\"FID\" = {0}".format(FID))
arcpy.CopyFeatures_management("lyr_MyIndividualLayer{0}".format(FID), "zzzShapefileName {0}.shp".format(FID))
print("Created ShapefileName {0}.shp".format(FID))