Summary: Double-clicking an .exe file may open Notepad or any other application, displaying junk characters. On some systems, the Open with dialog may appear when double-clicking .exe files. This article explains how to fix the .exe file association in Windows 10 and 11.
Did you accidentally use the Default Programs or Open With dialog to associate .exe file types with an application like Notepad? This causes every program to open in that chosen application. Unfortunately, Windows does not provide an option to reset the .exe file associations. You need to fix the association settings using a .reg file or script.
After incorrectly associating .exe files using Notepad, Notepad opens whenever a .exe file is double-clicked. Here is an example:

Or, you may see the “Open with” dialog when you run a program (.exe file).

Resolution
To fix the .exe file association issue, delete the UserChoice registry key. This has to be done using a REG file or a script, as trying to launch regedit.exe directly would cause the same problem. Follow these steps:
1) Run exefix_cu.reg
- Right-click exefix_cu.reg and choose “Save Link as” in your browser, and download the file to Desktop.
- Right-click on the REG file and choose Merge. The .REG file clears the following key, which shouldn’t exist for .exe files.
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.exe\UserChoice
When you use the Open With dialog to associate .exe files with another application, it stores the settings in the above registry key under a value named Progid. The Progid data will contain the application’s exe file name (Applications\Notepad.exe, Applications\iexplore.exe, or a Programmatic Identifier such as txtfile, jpegfile, etc).
2) Run exefix.reg
If the above fix doesn’t help, download exefix.reg (right-click and “Save link as” in your browser) and run it. Click Yes to confirm.
(The registry fix restores the .exe file association settings in Windows 10 and 11.)
Ignore the following error:
Cannot import exefix.reg: Not all data was successfully written to the registry. Some keys are open by the system or other processes, or you have insufficient privileges to perform this operation.
See if that fixes the .exe association settings.
Related article: How to Remove a File Association Using the Registry Editor?
One small request: If you liked this post, please share this?
One "tiny" share from you would seriously help a lot with the growth of this blog. Some great suggestions:- Pin it!
- Share it to your favorite blog + Facebook, Reddit
- Tweet it!
JUst did this because I am using Windows in a foregin language. Don’t know why the association got redirected, but thanks so much for this quick fix!!
It actually worked! Thank you!!! 🙂
Thank you so much man , i really appreciate your help 🙂
Thank you so much! My laptop is working again! My situation was especially nasty, as I accidentally set file exlporer to open .exe, so I was finally able to copy the registry editor to a USB and luckily file explorer still worked so I was able to open it.
This totally worked for my little guys laptop. He is a very happy boy. Thank you so much for the help……
Ahhhh! I think we fixed it!!! File Associations were all messed up! My kid decided to mess with the webcam on my laptop & somehow changed the Open With to Windows Photo Viewer….somehow it defaulted EVERYTHING to opening with that. I have been going nuts!
Totally worked! Thanks
Thanks so much! Double clicking any .exe was opening a cmd window.
Deleting FileExts/.exe/UserChoice fixed it.
How can we do this if we cannot open it or any browser to download this reg file?
This was owesome, never knew there was a way out of the .exe association. Thnks a bunch.
Thanks. Thought i would have to junk my old machine.
this is life saver .keep up the good work and thanks a lot.
Sir, Three Salutes to you. Thank you very much for this wonderful medicine to my laptop.
LOVE YOU SOOO MUCH, ITS SAVE ME !!!!!