On this page:
Introduction
IntelliJ IDEA enables running entire applications as well as classes with main() method .
IntelliJ IDEA makes use of the settings defined in a Run/Debug Configuration. All the run configurations that exist in a project, are available in the Select Run/Debug Configuration drop-down list.
If you want to see a list of all currently running applications, select from the main menu. Refer to the section Viewing Running Processes for details.
Running an application
- Do one of the following:
- In the left gutter, click the icon
, and choose the desired
command. - On the main toolbar, select the desired run configuration, and:
- Choose Run | Run from the main menu.
- Click
. - Press ⌃R⇧F10⇧⌘F11^ F5⇧ F10.
- Press ⌃⌥R⌥⇧F10⌃⌥R⇧ ⌥ F10⇧ ⌥ F10, select the desired run configuration from the pop-up menu, and press ⏎⏎⏎EnterEnter.

From this pop-up menu you can:
- Invoke the Edit Configuration dialog.
- Edit the selected configuration before launch (⌘↓F4F3F4F4).
- Instantly delete a temporary configuration (⌦⌦⌦DeleteDelete).
- Switch from run to debug and vice versa (hold ⇧).
- Access a previously selected configuration (1).
- Access context-dependent configuration (2 or 3).
This pop-up menu can also be quickly accessed by pressing F9, when you're not running any debug session.
If the options that launch build or before running were enabled, IntelliJ IDEA runs the build , and after success will run the application. Otherwise, the program will start immediately.
Note that after you've started a run session, the
icon that marks the Run tool window and in the Run/Debug Configuration
Selector toggles to
to indicate that the run process is active. - In the left gutter, click the icon
Running a class with main() method
- Open the class in the editor and do one of the following:
- In the left gutter, click the icon
, and choose the desired
command. - Choose on the context menu
- Press ⌃⇧R⌃⇧F10⌃⇧R^ F9^ ⇧ F10
- In the left gutter, click the icon
- Select the class in the Project tool window and choose on the context menu of the selection.