pandas drop extension name from list of files code example Example: pandas drop extension name from list of files df.names = df.names.str.split('.').str.get(0)