To change a file extension in Windows 11, open File Explorer, select View > Show > File name extensions, select the file and press F2. Replace the ending after the last period, press Enter, and confirm only if the new extension matches the file’s actual format.
Renaming does not convert a file. Changing document.txt to document.pdf does not create a PDF. For a different format, open the file in an app that supports it and use Save As or Export. This guide explains both tasks on Windows 11 and how to undo an incorrect rename.
Choose the Right Kind of Change
- Correct a wrong ending: rename the extension when you know the contents already match the new format. For example, a JPEG saved with
.jpegcan use.jpg; those names identify the same image format. - Create a different format: use an app’s conversion or export feature. A Word document and a PDF have different internal structures.
- Open the same file in a different app: change its Windows file association. You do not need to rename or convert it.
Microsoft’s file-extension guidance explains that changing the name does not change the contents. If you do not know the file’s real format, check with the app or person that created it before guessing an ending. Video is a common example: renaming an .avi file to .mp4 leaves the same codec inside, so fixing AVI playback on Windows 11 means choosing a player that supports it.
A .bin file is a common example: renaming it rarely helps, and opening a BIN file in Windows explains what to use instead.
If you only want a file to open in another program, change the default app in Windows 11 instead of renaming it.
How to Rename One File Extension in Windows 11
Before you start, make a copy of the file and close it in any app that has it open. Don’t rename programs or system files to try to make them open in a different app.
- Open the folder. Press Windows key + E and navigate to the file in File Explorer.
- Show its full ending. Select View > Show > File name extensions. You should see a name such as
photo.jpeg. The Folder Options alternative is in the Windows extension-display guide.

- Select the file and press F2. You can also right-click it and select Rename; hover over an icon if its label is not visible. Microsoft documents F2 in its rename-a-file instructions.
- Edit the extension itself. Windows may initially select only the base name. Click or move to the ending after the last period. For the same-format example, replace
jpegwithjpgwhile keeping the period and base name. - Confirm the name. Press Enter. If Windows warns that the file may become unusable, select Yes only when you know the new suffix is correct. Otherwise cancel.

- Check the result. Make sure the name shows
photo.jpg, then open the file in an app that supports JPEG. Only the name changes; the image isn’t converted.

Example: Change a TXT file to CFG in Windows 11
Suppose an app asks for settings.cfg and you have its settings saved as settings.txt. Make a copy first. In File Explorer, turn on View > Show > File name extensions, select the copy, press F2, and change the full name to settings.cfg. Press Enter and confirm the change. Check that Explorer shows settings.cfg, not settings.cfg.txt.
If you’re creating the file in Notepad, choose File > Save as, set Save as type to All files, and enter the exact filename the app expects. A CFG extension does not make arbitrary text a working configuration: the settings, filename, and folder must match that app’s instructions. Open the app and check that it picked up the settings before replacing your original file.
How to Create a Real Converted File
File Explorer can’t convert files. Open the file in an app that reads the original format and can save or export the one you need. Keep the original, because conversion can change the layout, quality, or editing features.
Example: a Word document to PDF
In the Windows desktop version of Word, follow Microsoft’s steps to save a document as a PDF:
- Open the original document in Word and check that it displays correctly.
- Select File > Save a Copy. In older versions of Word, select File > Save As.
- Select Browse, choose a folder and give the output a clear name.
- Choose PDF in the file-type drop-down.
- Select Save. Open the new PDF and check its pages. Keep the original Word document.
For a picture, audio, or video file, use an app that lists the format you want under Save As or Export. If the format isn’t listed, that app can’t make the conversion. Changing the extension won’t add support or fix a damaged file.
For iPhone pictures, it’s easiest to convert the iPhone photo to JPG on the phone, which creates a real JPEG copy instead of a renamed HEIC file.
Troubleshooting and Undo
- The extension is still hidden: revisit View > Show > File name extensions. Showing hidden items is a separate setting.
- The name ends in two types: check the full name. In
report.pdf.txt, the last ending is.txt. Remove it only if you know the file is really a PDF. - The file stops opening: press F2 again and restore the original extension. This reverses the name change, not edits or conversion done inside an app. Use your backup copy if needed.
- Rename is blocked: close the file’s app and check whether you have permission to modify that location. Ask the owner or administrator if access is restricted.
- The converted copy looks wrong: return to the original, adjust the app’s export options and make another copy. Check the output before sharing or deleting anything.
File Extension Change Questions
Can I turn a text file into PDF by renaming it?
No. The contents remain plain text. Use an app that can open the text and create PDF output, then check the new PDF. The same applies to renaming an image or video to a different format.
Can I change several extensions at once?
Yes. Here is how to change multiple file extensions at once in Windows 11. Renaming in bulk still doesn’t convert the files, so test the change on a copy of one file first.
Can I hide extensions afterward?
Yes. Clear File name extensions in the same File Explorer menu. That only changes display; it does not undo your rename. Keeping the endings visible makes it easier to check future changes.

Matthew Burleigh is the founder, head writer, and editor of Solve Your Tech, which he launched in 2012. He has written technology tutorials since 2008 and worked in IT since 2003, including small-business support, IT management, and consulting. He holds Bachelor’s and Master’s degrees in Computer Science from Arizona State University.
Matthew writes practical guides for Windows, iPhone and iPad, Microsoft Office, Outlook, Google apps, and Android. Solve Your Tech’s guides are checked step by step against the device or app maker’s own documentation and tested on his own devices whenever he has the hardware or software, with clear steps, sources, and update dates.
Read more about Matthew and how Solve Your Tech writes and updates its guides, or report a correction.