This tutorial explains ways to open notepad++ from Windows and MACOS.

Once Notepad++ is installed in windows, It adds the Notepad++ folder path to the environment variable PATH.

You can alternatively add the path to the environment variable using the below line.

For example, If this is installed in the C:\Program Files folder.

set PATH=%PATH%;C:\Program Files\Notepad++

How to open Notepad++ from the command line in Windows?

In Windows, you can start the notepad++ from GUI.

  • Go to Win + R key
  • Type notepad++, Next enter
  • It opens the Notepad++ editor

It is straightway to open Notepad++ from Interface.

Let’s see how to start a notepad++ from a command line.

  • Open a command line using Win + R and type cmd.exe

  • It opens a command prompt

  • type start notepad++

    C:\>start notepad++
    
  • It Opens notepad++

To open a file in Notepad++ from the command line.

 C:\>start notepad++ first.txt
 ```
first.txt is a text file that is opened in the editor.

Also, Run, Open a folder in Notepad++
```markup
 C:\>start notepad++ src
 ```
src is a folder in the current directory.



You can also create a batch file.

run.bat
```markup
start "" "C:\Program Files\Notepad++\notepad++.exe" %*

To open notepad++, Run run.bat from the command line.