Skip to content

Instantly share code, notes, and snippets.

@P1N2O
Last active February 20, 2024 12:45
Show Gist options
  • Star 6 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save P1N2O/bffa44f79724d74c96b9ffd3db0fc1af to your computer and use it in GitHub Desktop.
Save P1N2O/bffa44f79724d74c96b9ffd3db0fc1af to your computer and use it in GitHub Desktop.
Replacing Notepad with Notepad++ in Windows 10

Replacing Notepad with Notepad++ in Windows 10

  1. Start an elevated or administrator Command Prompt.

  2. Copy the following command and paste it in the Command Prompt window:

reg add "HKLM\Software\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\notepad.exe" /v "Debugger" /t REG_SZ /d "\"%ProgramFiles%\Notepad++\notepad++.exe\" -notepadStyleCmdline -z" /f

To undo (reverse) the replacement, use the following command:

reg delete "HKLM\Software\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\notepad.exe" /v "Debugger" /f
  1. Close Command Prompt.

Download REG File Here (Right-Click > Save link as...).

Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\notepad.exe]
"Debugger"="\"C:\\Program Files\\Notepad++\\notepad++.exe\" -notepadStyleCmdline -z"
@Owned67
Copy link

Owned67 commented Dec 30, 2023

be carefull with env...
%ProgramFiles% on a 64bits OS but 32 bits installer, it's installed on %ProgramFiles(x86)%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment