First turn on file name extensions in File Explorer (View > Show > File name extensions). Then select the file, press F2, change the letters after the dot, and press Enter. Select Yes when Windows asks if you’re sure.
Changing the extension doesn’t convert the file. If you need a different format, open the file and use Save as instead.
Applies to: Windows 11.
Change the extension
- Open File Explorer and turn on extensions: select View > Show > File name extensions. Pictures of each menu are in showing file extensions in Windows 11.
- Select the file and press F2. Or right-click it and select Rename.
- Change the letters after the last dot, such as .txt to .csv.

- Press Enter, then select Yes in the warning.
Windows warns that the file might become unusable. That’s because the extension tells Windows which app opens the file. If you pick the wrong one, change it back the same way. That warning is real: renaming is one of the ways testers create a broken Word file on purpose to check how apps react.
When changing the extension works
It works when the file’s contents already match the new type. For example:
- A text file you want to open as a .csv or .bat file.
- A file that was saved with the wrong extension by mistake.
Convert a file with Save as instead
To really change a file’s format, such as a picture to .png or a document to .pdf, open it in an app and save a new copy:
- Open the file in its app, such as Paint, Notepad or Word.
- Select File > Save as.
- Choose the new type in Save as type, then select Save.

This keeps the original file and makes a new one in the right format. On an older PC, follow the steps for changing a file type in Windows 10.
If changing the extension doesn’t work
- The file still shows its old type. The extension was hidden, so the file may now be named something like report.pdf.docx. Turn on extensions and rename it again.
- Windows asks for permission. The file is in a protected folder, such as Program Files. Copy it to Documents, rename the copy, and use that.
- The file won’t open after renaming. The new app can’t read the old format. Change the extension back, then convert the file with Save as or Export in the right app.
- There’s no F2 key. Right-click the file and select the Rename icon, or press Fn + F2 on laptops where F2 controls something else.
Frequently asked questions
Why can’t I see the extension to change it?
Windows hides common extensions by default. Turn on File name extensions in File Explorer’s View > Show menu.
Can I change many file extensions at once?
Yes, with a command. Open the folder in File Explorer, type cmd in the address bar, and press Enter. Then run a command like ren *.txt *.csv to change every .txt file in that folder to .csv. Only do this when the files really are in the new format, such as JFIF pictures that are already JPEG files.
How do I pick which app opens a file type?
Use the steps for changing the default PDF viewer in Windows 11. They work for other file types too.
Is it safe to change a file extension?
It doesn’t harm the file itself, and you can always change it back. Just don’t rename files to .exe or other program types, and be careful with files from people you don’t know.
Can renaming a file make it smaller?
No. The file stays exactly the same size. To make a file smaller, compress it, or save it in a smaller format from the app that made it.
What are some common file extensions?
.docx is a Word document, .xlsx is an Excel workbook, .pdf is a PDF, .jpg and .png are pictures, .mp3 is audio, .mp4 is video, and .txt is plain text. Knowing these helps you pick the right app to open or convert a file.
A longer list is in Microsoft’s Common file name extensions in Windows.

Matt Jacobs has been working as an IT consultant for small businesses since receiving his Master’s degree in 2003. While he still does some consulting work, his primary focus now is on creating technology support content for SupportYourTech.com.
His work can be found on many websites and focuses on topics such as Microsoft Office, Apple devices, Android devices, Photoshop, and more.