drop column if it exists pandas code example Example: is coumn exist then delete in datafrmae if 'A' in df.columns: del df['A']