This should be faster than looping:
# Using boolean indexing to find the cutoff index cutoff_index = df[df['stage'] != 0].index.min() # Slice and reset index df = df.iloc[cutoff_index:].reset_index(drop=True) print(df)