Open Settings > Apps
In the center pane select Advanced app settings > App execution aliases
Toggle off Notepad
Then go to the old Notepad at C:\Windows\Notepad.exe and right click > Pin to the taskbar/Pin to start/Send to Desktop
Thank you for this, _AW_. It worked for me on Windows 11 Pro for Workstations, version 10.0.22641.
After the setting change, running "notepad" (or C:\Windows\notepad.exe or C:\Windows\System32\notepad.exe) from a command prompt now takes me to old Notepad. Before I made the the setting change they all took me to the new Notepad. I think the setting change is probably just a registry setting which C:\Windows\notepad.exe queries, to decide whether or not to immediately chain to the new Notepad, on startup.
Surprisingly, however, the existing shortcuts to the new Notepad which I'd already pinned to the Start menu and Taskbar still takes me to the new Notepad.
M$ seems to have gone to considerable trouble hide how that works. There's no "Notepad" shortcut file in either C:\ProgramData\Microsoft\Windows\Start Menu\Programs\ or C:\Users%USERNAME%\AppData\Roaming\Microsoft\Windows\Start Menu\Programs. Task Manager reports that the classic Notepad is in C:\Windows\ but the new Notepad is in C:\Program Files\WindowsApps\Microsoft.WindowsNotepad_11.2405.13.0_x64__8wekyb3d8bbwe\Notepad.
Indeed, there is a notepad.exe program in that folder, but simply running it directly does not work. It doesn't report an error, it just exits immediately. Apparently it only works if chained-to from C:\Windows\notepad.exe. Why does M$ have to be so obscure about everything??
But, anyhow, now I have both working shortcuts on my Start menu: one to "Notepad" (the new one), and one to "Notepad (classic)".