🕷️ Crawler Inspector

URL Lookup

Direct Parameter Lookup

Raw Queries and Responses

1. Shard Calculation

Query:
Response:
Calculated Shard: 95 (from laksa180)

2. Crawled Status Check

Query:
Response:

3. Robots.txt Check

Query:
Response:

4. Spam/Ban Check

Query:
Response:

5. Seen Status Check

ℹ️ Skipped - page is already crawled

📄
INDEXABLE
CRAWLED
4 days ago
🤖
ROBOTS ALLOWED

Page Info Filters

FilterStatusConditionDetails
HTTP statusPASSdownload_http_code = 200HTTP 200
Age cutoffPASSdownload_stamp > now() - 6 MONTH0.1 months ago
History dropPASSisNull(history_drop_reason)No drop reason
Spam/banPASSfh_dont_index != 1 AND ml_spam_score = 0ml_spam_score=0
CanonicalPASSmeta_canonical IS NULL OR = '' OR = src_unparsedNot set

Page Details

PropertyValue
URLhttps://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html
Last Crawled2026-04-02 17:48:07 (4 days ago)
First Indexed2023-04-22 02:54:22 (2 years ago)
HTTP Status Code200
Meta TitleRun/debug configuration: Application | IntelliJ IDEA Documentation
Meta Descriptionnull
Meta Canonicalnull
Boilerpipe Text
Last modified: 11 November 2024 Application is the most basic run/debug configuration template for Java applications. This configuration compiles and runs your Java program – similar to when you use the javac and java commands. . Open the run configuration  In the main menu, go to Run | Edit Configurations . In the Run/Debug Configuration dialog: To create a new configuration, click on the toolbar or press Alt Insert and select Application . Alternatively, click an existing Application configuration in the list on the left. On the right, you will see configuration options. tip Required options  Item Description JRE Specify the runtime environment that IntelliJ IDEA should use to run the application. By default, IntelliJ IDEA uses the latest available JDK from the module dependencies. Main class Specify the fully qualified name of the class to be executed. Program arguments Specify a list of arguments to be passed to the application in the format you would use on the command line. Use the same rules as for specifying VM options. Working directory Specify the working directory to be used for running the application. This directory is the starting point for all relative input and output paths. By default, the working directory is the project root. More options  You can also configure additional properties for the Application run/debug configuration type. To access them, click Modify options : Operating system  Item Description Allow multiple instances Allow multiple instances of this run configuration to execute at the same time. By default, this option is disabled, which means that when you run the configuration, other active sessions of the configuration will terminate. Environment variables Click to open the Environment Variables dialog where you can create variables and specify their values. Redirect input Enables redirecting data from a text file to standard input. Use this option if your program requires some input, and you want to read the values from a file instead of typing them in the Run console. To enable redirecting, select the checkbox and specify the path to the target text file. Java  The following options are specific to the Java compiler and runtime: Item Description Do not build before run Run the application straight away without launching the build process. Use classpath of module Select the module whose classpath should be used to run the application. Modify classpath If necessary, specify another classpath or select dependencies that you want to exclude from the classpath. This option is necessary in cases when the runtime classpath is different from the compile classpath (debug libraries, different locations, and so on). Use the and buttons to sort dependencies on the list. The order of dependencies is important as IntelliJ IDEA will process them in the same order as they are specified in the list. Add dependencies with “provided” scope to classpath Add the dependencies with the provided scope to the runtime classpath. Shorten command line Select a method that will be used to shorten the command line if the classpath gets too long, or you have many VM arguments that exceed your OS command line length limitation. The choice of option depends on the class loader implementation. Note that some frameworks do not support JAR manifest , while other frameworks with custom class loaders will not work well with the classpath.file option. none : IntelliJ IDEA will not shorten a long classpath. If the command line exceeds the OS limitation, IntelliJ IDEA will be unable to run your application and will display a message suggesting that you specify the shortening method. JAR manifest : IntelliJ IDEA will pass a long classpath via a temporary classpath.jar . The original classpath is defined in the manifest file as a class-path attribute in classpath.jar . Note that you will be able to preview the full command line if it was shortened using this method, not just the classpath of the temporary classpath.jar . classpath.file : IntelliJ IDEA will write a long classpath into a text file. @argFiles (Java 9+) : the command-line length limitations will be overcome using the @argument files option . note This setting is shared if you select to share your run/debug configuration, so the same method will be applied for your team members irrespective of their operating system. VM options Specify the options to be passed to the Java virtual machine when launching the application, for example, -mx , -verbose , and so on. When specifying JVM options, follow these rules: Use spaces to separate individual options. If the value of an option includes spaces, enclose either the value or the actual spaces with double quotes. If an option includes double quotes as part of the value, escape the double quotes using backslashes. You can pass environment variable values to custom Java properties. -Xmx1024m -Dspaces="some arg" -Dmy.prop=\"quoted_value\" -Dfoo=${MY_ENV_VAR} Use code completion in this field: start typing the name of a flag, and the IDE suggests a list of available command line options. This works for -XX: and -X options and some standard options that are not configured by IntelliJ IDEA automatically, like -ea , but not for -cp or –release . The -classpath option specified in this field overrides the classpath of the module. Logs  The following options are related to logging the execution of this configuration. For more information, refer to Logs . Item Description Specify logs to be shown in the console Specify which log files to display while running the application. Click to add a new log. In the Edit Log Files Aliases dialog, configure the following: Alias : The name of the tab where the log will be displayed. Log File Location : Specify the path to the log file or an Ant pattern . If several files of a rolling log match the pattern, IntelliJ IDEA will display the most recent one. Show all files coverable by pattern : Show all logs that match the pattern. For logs in the table, you can configure the following options: Is Active : Display the specified log file. Skip Content : Do not display old log messages from previous runs. Save console output to file Save the console output to the specified location. Type the path manually or click the browse button and point to the desired location in the dialog that opens . Show console when a message is printed to stdout Activate the console when the application writes to the standard output stream. Show console when a message is printed to stderr Activate the console when the application writes to the standard error stream. Code Coverage  The following options are related to code coverage. For more information, refer to Code coverage . Item Description Specify classes and packages In this table, specify classes and packages to be measured. Click and select Add Class or Add Package to specify. You can also remove classes and packages from the list by selecting them in the list and clicking the button. Exclude classes and packages Specify classes and packages that you want to exclude from coverage. Click and select Add Class or Add Package to specify classes and packages. Before Launch  In this area, you can specify tasks to be performed before starting the selected run/debug configuration. The tasks are performed in the order they appear in the list. Item Description Add before launch task Enable this option to add one of the following available tasks: Launch Web Browser : select this option to have a browser started. In the dialog that opens, select the type of the browser and provide the start URL. Also, specify if you want the browser be launched with JavaScript debugger. Run External tool : run an external application. In the dialog that opens, select one or multiple applications you want to run. If it is not defined in IntelliJ IDEA yet, add its definition. For more information, refer to External tools . Run Another Configuration : select to execute another run/debug configuration and wait until it finishes before starting the current configuration. If you want to run several configurations in parallel, use a compound run/debug configuration . Run Remote External Tool : add a remote SSH external tool . Run Gradle task : run a Gradle task . In the dialog that opens, specify the task and provide additional configuration if necessary. Build : select to compile the specified module. The Build Module action will be executed. If an error occurs during compilation, IntelliJ IDEA won't attempt to start the run/debug configuration. Build Project : select to compile the entire project. The Build Project action will be executed. If an error occurs during compilation, IntelliJ IDEA won't attempt to start the run/debug configuration. Build, no error check : the same as the Build option, but IntelliJ IDEA will try to start the run/debug configuration irrespective of the compilation results. Build Artifacts : select this option to build an artifact or artifacts. In the dialog that opens, select the artifact or artifacts that should be built. Run Maven Goal : select this option to run a Maven goal . In the dialog that opens, select the goal to be run. Run Grunt task : select this option to run a Grunt task. In the Grunt task dialog that opens, specify the Gruntfile.js where the required task is defined, select the task to execute, and specify the arguments to pass to the Grunt tool. Specify the location of the Node.js runtime, the parameters to pass to it, and the path to the grunt-cli package. Run gulp task : select this option to run a Gulp task. In the Gulp task dialog that opens, specify the Gulpfile.js where the required task is defined, select the task to execute, and specify the arguments to pass to the Gulp tool. Specify the location of the Node.js runtime, the parameters to pass to it, and the path to the gulp package. Run npm script : select this option to execute an npm script. In the NPM Script dialog that opens, specify the npm run/debug configuration settings . Compile TypeScript : select to run the built-in TypeScript compiler and thus make sure that all the changes you made to your TypeScript code are reflected in the generated JavaScript files. In the TypeScript Compile Settings dialog that opens, select or clear the Check errors checkbox to configure the behaviour of the compiler in case any errors are detected: If the Check errors checkbox is selected, the compiler will show all the errors and the run configuration will not start. If the Check errors checkbox is cleared, the compiler will show all the detected errors but the run configuration still will be launched. Disconnect Data Source : select this option if you want to disrupt the connection to a data source before the run/debug configuration is run. Open run/debug tool window when started Depending on the type of configuration, open the Run , Debug , or Services tool window when you start this run configuration. If this option is disabled, you can open the tool window manually: View | Tool Windows | Run or Alt 0 4 View | Tool Windows | Debug or Alt 0 5 View | Tool Windows | Services or Alt 0 8 Focus run/debug tool window when started Focus on the run configuration tool window when the tests are running. Show the run/debug configuration settings before start Show the run configuration settings before actually starting it.
Markdown
IntelliJ IDEA 2026\.1 Shortcuts: Windows [Get IntelliJ IDEA](https://www.jetbrains.com/idea/download/) [ConferenceJoin 2,000+ devs and Kotlin enthusiasts at KotlinConf, Munich, May 2026](https://jb.gg/parm9c) - [New in IntelliJ IDEA 2026.1](https://www.jetbrains.com/help/idea/new-in-this-release.html) - [Getting started](https://www.jetbrains.com/help/idea/getting-started.html) - [IDE configuration](https://www.jetbrains.com/help/idea/configuring-project-and-ide-settings.html) - [Project configuration](https://www.jetbrains.com/help/idea/working-with-projects.html) - [Search everywhere](https://www.jetbrains.com/help/idea/searching-everywhere.html) - [Write and edit source code](https://www.jetbrains.com/help/idea/working-with-source-code.html) - [Compilation and building](https://www.jetbrains.com/help/idea/compiling-applications.html) - [Running](https://www.jetbrains.com/help/idea/running-applications.html) - [Run/debug configurations](https://www.jetbrains.com/help/idea/run-debug-configuration.html) - [Run/debug configuration: Application](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html) - [Program arguments, VM options, environment variables](https://www.jetbrains.com/help/idea/program-arguments-and-environment-variables.html) - [List of run/debug configuration templates](https://www.jetbrains.com/help/idea/list-of-run-debug-configurations.html) - [Tutorial: Run a Java application](https://www.jetbrains.com/help/idea/run-java-applications.html) - [Run compound tasks](https://www.jetbrains.com/help/idea/run-debug-multiple.html) - [Logs](https://www.jetbrains.com/help/idea/setting-log-options.html) - [Run anything](https://www.jetbrains.com/help/idea/running-anything.html) - [Run shebang scripts](https://www.jetbrains.com/help/idea/shebang-scripts.html) - [Run targets](https://www.jetbrains.com/help/idea/run-targets.html) - [Services tool window](https://www.jetbrains.com/help/idea/using-services-tool-window.html) - [Run tool window](https://www.jetbrains.com/help/idea/run-tool-window.html) - [Debugging](https://www.jetbrains.com/help/idea/debugging-code.html) - [Deployment](https://www.jetbrains.com/help/idea/deploying-applications.html) - [Testing](https://www.jetbrains.com/help/idea/tests-in-ide.html) - [Analysis](https://www.jetbrains.com/help/idea/analysis.html) - [Version control](https://www.jetbrains.com/help/idea/version-control-integration.html) - [AI](https://www.jetbrains.com/help/idea/ai.html) - [Remote development](https://www.jetbrains.com/help/idea/remote.html) - [Dev Containers](https://www.jetbrains.com/help/idea/dev-containers-starting-page.html) - [Integrated tools](https://www.jetbrains.com/help/idea/integrated-tools.html) - [Web development](https://www.jetbrains.com/help/idea/web-development.html) - [Database Tools and SQL](https://www.jetbrains.com/help/idea/relational-databases.html) - [JVM frameworks](https://www.jetbrains.com/help/idea/jvm-frameworks.html) - [Kotlin](https://www.jetbrains.com/help/idea/get-started-with-kotlin.html) - [Scala](https://www.jetbrains.com/help/idea/get-started-with-scala.html) - [Groovy](https://www.jetbrains.com/help/idea/groovy.html) - [Non-JVM technologies](https://www.jetbrains.com/help/idea/non-jvm-technologies.html) - Reference 1. [Running](https://www.jetbrains.com/help/idea/running-applications.html) 2. [Run/debug configuration: Application](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#0) # Run/debug configuration: Application Last modified: 11 November 2024 Application is the most basic run/debug configuration template for Java applications. This configuration compiles and runs your Java program – similar to when you use the `javac` and `java` commands. . ### Open the run configuration 1. In the main menu, go to Run \| Edit Configurations. 2. In the Run/Debug Configuration dialog: - To create a new configuration, click ![Add](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) on the toolbar or press `Alt``Insert` and select Application. - Alternatively, click an existing Application configuration in the list on the left. On the right, you will see configuration options. ![Run/Debug Configuration: Application](https://resources.jetbrains.com/help/img/idea/2026.1/run-java-app-main-config.png) > ### tip > You can use `Ctrl``Space` to let IntelliJ IDEA [help you fill in the fields](https://www.jetbrains.com/help/idea/auto-completing-code.html) in this dialog. | | | |---|---| | Name | Specify a name for the run configuration to quickly identify it among others when editing or running. | | Run on | Select the target environment where you want to run the configuration. Besides running it locally, you can select to run your application on a remote machine via SSH or in a Docker container. For more information, refer to [Run targets](https://www.jetbrains.com/help/idea/run-targets.html). | | Store as project file | Save the run configuration settings to a file that you can share with other team members. The default location is .idea/runConfigurations. However, if you do not want to share the .idea directory, you can save the configuration to any other directory within the project.By default, this option is disabled, and IntelliJ IDEA stores run configuration settings in .idea/workspace.xml. | ## Required options | Item | Description | |---|---| | JRE | Specify the runtime environment that IntelliJ IDEA should use to run the application. By default, IntelliJ IDEA uses the latest available JDK from the module dependencies. | | Main class | Specify the fully qualified name of the class to be executed. | | Program arguments | Specify a list of arguments to be passed to the application in the format you would use on the command line. Use the same rules as for specifying VM options. | | Working directory | Specify the working directory to be used for running the application. This directory is the starting point for all relative input and output paths. By default, the working directory is the project root. | ## More options You can also configure additional properties for the Application run/debug configuration type. To access them, click Modify options: ![Run/Debug Configuration: Application, More Options](https://resources.jetbrains.com/help/img/idea/2026.1/run-debug-application-more.png) ## Operating system | Item | Description | |---|---| | Allow multiple instances | Allow multiple instances of this run configuration to execute at the same time. By default, this option is disabled, which means that when you run the configuration, other active sessions of the configuration will terminate. | | Environment variables | Click ![the Browse button](https://resources.jetbrains.com/help/img/idea/2026.1/app.general.inlineVariables.svg) to open the Environment Variables dialog where you can create variables and specify their values. | | Redirect input | Enables redirecting data from a text file to standard input. Use this option if your program requires some input, and you want to read the values from a file instead of typing them in the Run console. To enable redirecting, select the checkbox and specify the path to the target text file. | ## Java The following options are specific to the Java compiler and runtime: | Item | Description | |---|---| | Do not build before run | Run the application straight away without launching the build process. | | Use classpath of module | Select the module whose classpath should be used to run the application. | | Modify classpath | If necessary, specify another classpath or select dependencies that you want to exclude from the classpath. This option is necessary in cases when the runtime classpath is different from the compile classpath (debug libraries, different locations, and so on).Use the ![Up](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.moveUp.svg) and ![Down](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.moveDown.svg) buttons to sort dependencies on the list. The order of dependencies is important as IntelliJ IDEA will process them in the same order as they are specified in the list. | | Add dependencies with “provided” scope to classpath | Add the dependencies with the provided scope to the runtime classpath. | | Shorten command line | Select a method that will be used to shorten the command line if the classpath gets too long, or you have many VM arguments that exceed your OS command line length limitation. The choice of option depends on the class loader implementation. Note that some frameworks do not support JAR manifest, while other frameworks with custom class loaders will not work well with the classpath.file option.none: IntelliJ IDEA will not shorten a long classpath. If the command line exceeds the OS limitation, IntelliJ IDEA will be unable to run your application and will display a message suggesting that you specify the shortening method. JAR manifest: IntelliJ IDEA will pass a long classpath via a temporary classpath.jar. The original classpath is defined in the manifest file as a `class-path` attribute in classpath.jar. Note that you will be able to preview the full command line if it was shortened using this method, not just the classpath of the temporary classpath.jar. classpath.file: IntelliJ IDEA will write a long classpath into a text file. @argFiles (Java 9+): the command-line length limitations will be overcome using the [@argument files option](https://docs.oracle.com/javase/9/tools/java.htm#JSWOR-GUID-4856361B-8BFD-4964-AE84-121F5F6CF111).note This setting is shared if you select to share your run/debug configuration, so the same method will be applied for your team members irrespective of their operating system. | | VM options | Specify the options to be passed to the Java virtual machine when launching the application, for example, `-mx`, `-verbose`, and so on.When specifying JVM options, follow these rules:Use spaces to separate individual options. If the value of an option includes spaces, enclose either the value or the actual spaces with double quotes. If an option includes double quotes as part of the value, escape the double quotes using backslashes. You can pass environment variable values to custom Java properties.Use code completion in this field: start typing the name of a flag, and the IDE suggests a list of available command line options. This works for `-XX:` and `-X` options and some standard options that are not configured by IntelliJ IDEA automatically, like `-ea`, but not for `-cp` or `–release`.The `-classpath` option specified in this field overrides the classpath of the module. | ## Logs The following options are related to logging the execution of this configuration. For more information, refer to [Logs](https://www.jetbrains.com/help/idea/setting-log-options.html). | Item | Description | |---|---| | Specify logs to be shown in the console | Specify which log files to display while running the application.Click ![the Add button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) to add a new log. In the Edit Log Files Aliases dialog, configure the following:Alias: The name of the tab where the log will be displayed. Log File Location: Specify the path to the log file or an [Ant pattern](https://ant.apache.org/manual/dirtasks.html). If several files of a rolling log match the pattern, IntelliJ IDEA will display the most recent one. Show all files coverable by pattern: Show all logs that match the pattern.For logs in the table, you can configure the following options:Is Active: Display the specified log file. Skip Content: Do not display old log messages from previous runs. | | Save console output to file | Save the console output to the specified location. Type the path manually or click the browse button and point to the desired location in the dialog that opens. | | Show console when a message is printed to stdout | Activate the console when the application writes to the standard output stream. | | Show console when a message is printed to stderr | Activate the console when the application writes to the standard error stream. | ## Code Coverage The following options are related to code coverage. For more information, refer to [Code coverage](https://www.jetbrains.com/help/idea/code-coverage.html). | Item | Description | |---|---| | Specify classes and packages | In this table, specify classes and packages to be measured. Click ![the Add button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) and select ![the Add Class button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.class.svg) Add Class or ![the Add Package button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.package.png) Add Package to specify. You can also remove classes and packages from the list by selecting them in the list and clicking the ![remove the package](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.remove.svg) button. | | Exclude classes and packages | Specify classes and packages that you want to exclude from coverage.Click ![the Add button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) and select ![the Add Class button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.class.svg) Add Class or ![the Add Package button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.package.png) Add Package to specify classes and packages. | ## Before Launch In this area, you can specify tasks to be performed before starting the selected run/debug configuration. The tasks are performed in the order they appear in the list. | Item | Description | |---|---| | Add before launch task | Enable this option to add one of the following available tasks:Launch Web Browser: select this option to have a browser started. In the dialog that opens, select the type of the browser and provide the start URL. Also, specify if you want the browser be launched with JavaScript debugger. Run External tool: run an external application. In the dialog that opens, select one or multiple applications you want to run. If it is not defined in IntelliJ IDEA yet, add its definition. For more information, refer to [External tools](https://www.jetbrains.com/help/idea/configuring-third-party-tools.html). Run Another Configuration: select to execute another run/debug configuration and wait until it finishes before starting the current configuration. If you want to run several configurations in parallel, use a [compound run/debug configuration](https://www.jetbrains.com/help/idea/run-debug-multiple.html#compound-configs). Run Remote External Tool: add a [remote SSH external tool](https://www.jetbrains.com/help/idea/settings-tools-remote-ssh-external-tools.html). Run Gradle task: run a [Gradle task](https://www.jetbrains.com/help/idea/create-run-debug-configuration-gradle-tasks.html). In the dialog that opens, specify the task and provide additional configuration if necessary. Build: select to compile the specified module. The [Build Module](https://www.jetbrains.com/help/idea/compiling-applications.html#compile_module) action will be executed. If an error occurs during compilation, IntelliJ IDEA won't attempt to start the run/debug configuration. Build Project: select to compile the entire project. The [Build Project](https://www.jetbrains.com/help/idea/compiling-applications.html#compile_module) action will be executed. If an error occurs during compilation, IntelliJ IDEA won't attempt to start the run/debug configuration. Build, no error check: the same as the Build option, but IntelliJ IDEA will try to start the run/debug configuration irrespective of the compilation results. Build Artifacts: select this option to build an [artifact](https://www.jetbrains.com/help/idea/working-with-artifacts.html) or artifacts. In the dialog that opens, select the artifact or artifacts that should be built. Run Maven Goal: select this option to [run a Maven goal](https://www.jetbrains.com/help/idea/work-with-maven-goals.html). In the dialog that opens, select the goal to be run. Run Grunt task: select this option to run a Grunt task. In the Grunt task dialog that opens, specify the Gruntfile.js where the required task is defined, select the task to execute, and specify the arguments to pass to the Grunt tool. Specify the location of the Node.js runtime, the parameters to pass to it, and the path to the grunt-cli package. Run gulp task: select this option to run a Gulp task. In the Gulp task dialog that opens, specify the Gulpfile.js where the required task is defined, select the task to execute, and specify the arguments to pass to the Gulp tool. Specify the location of the Node.js runtime, the parameters to pass to it, and the path to the gulp package. Run npm script: select this option to execute an npm script. In the NPM Script dialog that opens, specify the [npm run/debug configuration settings](https://www.jetbrains.com/help/idea/installing-and-removing-external-software-using-node-package-manager.html). Compile TypeScript: select to run the built-in TypeScript compiler and thus make sure that all the changes you made to your TypeScript code are reflected in the generated JavaScript files. In the TypeScript Compile Settings dialog that opens, select or clear the Check errors checkbox to configure the behaviour of the compiler in case any errors are detected: If the Check errors checkbox is selected, the compiler will show all the errors and the run configuration will not start. If the Check errors checkbox is cleared, the compiler will show all the detected errors but the run configuration still will be launched. Disconnect Data Source: select this option if you want to disrupt the connection to a data source before the run/debug configuration is run. | | Open run/debug tool window when started | Depending on the type of configuration, open the [Run](https://www.jetbrains.com/help/idea/run-tool-window.html), [Debug](https://www.jetbrains.com/help/idea/debug-tool-window.html), or [Services](https://www.jetbrains.com/help/idea/services-tool-window.html) tool window when you start this run configuration. If this option is disabled, you can open the tool window manually:View \| Tool Windows \| Run or `Alt``04` View \| Tool Windows \| Debug or `Alt``05` View \| Tool Windows \| Services or `Alt``08` | | Focus run/debug tool window when started | Focus on the run configuration tool window when the tests are running. | | Show the run/debug configuration settings before start | Show the run configuration settings before actually starting it. | Thanks for your feedback\! Was this page helpful? Yes No - [Run/debug configuration: Application](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html) - [Required options](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#required) - [More options](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#more_options) - [Operating system](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#operating-system) - [Java](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#java) - [Logs](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#logs) - [Code Coverage](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#code_coverage) - [Before Launch](https://www.jetbrains.com/help/idea/run-debug-configuration-java-application.html#more_options_before_launch) ### See also #### Related - [Run/debug configurations](https://www.jetbrains.com/help/idea/run-debug-configuration.html) [Run/debug configurations](https://www.jetbrains.com/help/idea/run-debug-configuration.html) [Program arguments, VM options, environment variables](https://www.jetbrains.com/help/idea/program-arguments-and-environment-variables.html) - [What's new](https://www.jetbrains.com/idea/whatsnew/) - [Issue tracker](https://youtrack.jetbrains.com/issues/IDEA) - [Submit support request](https://intellij-support.jetbrains.com/hc/en-us/requests/new?ticket_form_id=66731) - [Privacy & Security](https://www.jetbrains.com/privacy-security/) - [Terms Of Use](https://www.jetbrains.com/legal/docs/company/useterms/) - [Trademarks](https://www.jetbrains.com/legal/trademarks/) - [Legal](https://www.jetbrains.com/legal/#licensing) Copyright © 2000–2026 JetBrains s.r.o.
Readable Markdown
Last modified: 11 November 2024 Application is the most basic run/debug configuration template for Java applications. This configuration compiles and runs your Java program – similar to when you use the `javac` and `java` commands. . Open the run configuration 1. In the main menu, go to Run \| Edit Configurations. 2. In the Run/Debug Configuration dialog: - To create a new configuration, click ![Add](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) on the toolbar or press `Alt``Insert` and select Application. - Alternatively, click an existing Application configuration in the list on the left. On the right, you will see configuration options. ![Run/Debug Configuration: Application](https://resources.jetbrains.com/help/img/idea/2026.1/run-java-app-main-config.png) > ### tip Required options | Item | Description | |---|---| | JRE | Specify the runtime environment that IntelliJ IDEA should use to run the application. By default, IntelliJ IDEA uses the latest available JDK from the module dependencies. | | Main class | Specify the fully qualified name of the class to be executed. | | Program arguments | Specify a list of arguments to be passed to the application in the format you would use on the command line. Use the same rules as for specifying VM options. | | Working directory | Specify the working directory to be used for running the application. This directory is the starting point for all relative input and output paths. By default, the working directory is the project root. | More options You can also configure additional properties for the Application run/debug configuration type. To access them, click Modify options: ![Run/Debug Configuration: Application, More Options](https://resources.jetbrains.com/help/img/idea/2026.1/run-debug-application-more.png) Operating system | Item | Description | |---|---| | Allow multiple instances | Allow multiple instances of this run configuration to execute at the same time. By default, this option is disabled, which means that when you run the configuration, other active sessions of the configuration will terminate. | | Environment variables | Click ![the Browse button](https://resources.jetbrains.com/help/img/idea/2026.1/app.general.inlineVariables.svg) to open the Environment Variables dialog where you can create variables and specify their values. | | Redirect input | Enables redirecting data from a text file to standard input. Use this option if your program requires some input, and you want to read the values from a file instead of typing them in the Run console. To enable redirecting, select the checkbox and specify the path to the target text file. | Java The following options are specific to the Java compiler and runtime: | Item | Description | |---|---| | Do not build before run | Run the application straight away without launching the build process. | | Use classpath of module | Select the module whose classpath should be used to run the application. | | Modify classpath | If necessary, specify another classpath or select dependencies that you want to exclude from the classpath. This option is necessary in cases when the runtime classpath is different from the compile classpath (debug libraries, different locations, and so on).Use the ![Up](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.moveUp.svg) and ![Down](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.moveDown.svg) buttons to sort dependencies on the list. The order of dependencies is important as IntelliJ IDEA will process them in the same order as they are specified in the list. | | Add dependencies with “provided” scope to classpath | Add the dependencies with the provided scope to the runtime classpath. | | Shorten command line | Select a method that will be used to shorten the command line if the classpath gets too long, or you have many VM arguments that exceed your OS command line length limitation. The choice of option depends on the class loader implementation. Note that some frameworks do not support JAR manifest, while other frameworks with custom class loaders will not work well with the classpath.file option.none: IntelliJ IDEA will not shorten a long classpath. If the command line exceeds the OS limitation, IntelliJ IDEA will be unable to run your application and will display a message suggesting that you specify the shortening method. JAR manifest: IntelliJ IDEA will pass a long classpath via a temporary classpath.jar. The original classpath is defined in the manifest file as a `class-path` attribute in classpath.jar. Note that you will be able to preview the full command line if it was shortened using this method, not just the classpath of the temporary classpath.jar. classpath.file: IntelliJ IDEA will write a long classpath into a text file. @argFiles (Java 9+): the command-line length limitations will be overcome using the [@argument files option](https://docs.oracle.com/javase/9/tools/java.htm#JSWOR-GUID-4856361B-8BFD-4964-AE84-121F5F6CF111).note This setting is shared if you select to share your run/debug configuration, so the same method will be applied for your team members irrespective of their operating system. | | VM options | Specify the options to be passed to the Java virtual machine when launching the application, for example, `-mx`, `-verbose`, and so on.When specifying JVM options, follow these rules:Use spaces to separate individual options. If the value of an option includes spaces, enclose either the value or the actual spaces with double quotes. If an option includes double quotes as part of the value, escape the double quotes using backslashes. You can pass environment variable values to custom Java properties.Use code completion in this field: start typing the name of a flag, and the IDE suggests a list of available command line options. This works for `-XX:` and `-X` options and some standard options that are not configured by IntelliJ IDEA automatically, like `-ea`, but not for `-cp` or `–release`.The `-classpath` option specified in this field overrides the classpath of the module. | Logs The following options are related to logging the execution of this configuration. For more information, refer to [Logs](https://www.jetbrains.com/help/idea/setting-log-options.html). | Item | Description | |---|---| | Specify logs to be shown in the console | Specify which log files to display while running the application.Click ![the Add button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) to add a new log. In the Edit Log Files Aliases dialog, configure the following:Alias: The name of the tab where the log will be displayed. Log File Location: Specify the path to the log file or an [Ant pattern](https://ant.apache.org/manual/dirtasks.html). If several files of a rolling log match the pattern, IntelliJ IDEA will display the most recent one. Show all files coverable by pattern: Show all logs that match the pattern.For logs in the table, you can configure the following options:Is Active: Display the specified log file. Skip Content: Do not display old log messages from previous runs. | | Save console output to file | Save the console output to the specified location. Type the path manually or click the browse button and point to the desired location in the dialog that opens. | | Show console when a message is printed to stdout | Activate the console when the application writes to the standard output stream. | | Show console when a message is printed to stderr | Activate the console when the application writes to the standard error stream. | Code Coverage The following options are related to code coverage. For more information, refer to [Code coverage](https://www.jetbrains.com/help/idea/code-coverage.html). | Item | Description | |---|---| | Specify classes and packages | In this table, specify classes and packages to be measured. Click ![the Add button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) and select ![the Add Class button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.class.svg) Add Class or ![the Add Package button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.package.png) Add Package to specify. You can also remove classes and packages from the list by selecting them in the list and clicking the ![remove the package](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.remove.svg) button. | | Exclude classes and packages | Specify classes and packages that you want to exclude from coverage.Click ![the Add button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.general.add.svg) and select ![the Add Class button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.class.svg) Add Class or ![the Add Package button](https://resources.jetbrains.com/help/img/idea/2026.1/app.expui.nodes.package.png) Add Package to specify classes and packages. | Before Launch In this area, you can specify tasks to be performed before starting the selected run/debug configuration. The tasks are performed in the order they appear in the list. | Item | Description | |---|---| | Add before launch task | Enable this option to add one of the following available tasks:Launch Web Browser: select this option to have a browser started. In the dialog that opens, select the type of the browser and provide the start URL. Also, specify if you want the browser be launched with JavaScript debugger. Run External tool: run an external application. In the dialog that opens, select one or multiple applications you want to run. If it is not defined in IntelliJ IDEA yet, add its definition. For more information, refer to [External tools](https://www.jetbrains.com/help/idea/configuring-third-party-tools.html). Run Another Configuration: select to execute another run/debug configuration and wait until it finishes before starting the current configuration. If you want to run several configurations in parallel, use a [compound run/debug configuration](https://www.jetbrains.com/help/idea/run-debug-multiple.html#compound-configs). Run Remote External Tool: add a [remote SSH external tool](https://www.jetbrains.com/help/idea/settings-tools-remote-ssh-external-tools.html). Run Gradle task: run a [Gradle task](https://www.jetbrains.com/help/idea/create-run-debug-configuration-gradle-tasks.html). In the dialog that opens, specify the task and provide additional configuration if necessary. Build: select to compile the specified module. The [Build Module](https://www.jetbrains.com/help/idea/compiling-applications.html#compile_module) action will be executed. If an error occurs during compilation, IntelliJ IDEA won't attempt to start the run/debug configuration. Build Project: select to compile the entire project. The [Build Project](https://www.jetbrains.com/help/idea/compiling-applications.html#compile_module) action will be executed. If an error occurs during compilation, IntelliJ IDEA won't attempt to start the run/debug configuration. Build, no error check: the same as the Build option, but IntelliJ IDEA will try to start the run/debug configuration irrespective of the compilation results. Build Artifacts: select this option to build an [artifact](https://www.jetbrains.com/help/idea/working-with-artifacts.html) or artifacts. In the dialog that opens, select the artifact or artifacts that should be built. Run Maven Goal: select this option to [run a Maven goal](https://www.jetbrains.com/help/idea/work-with-maven-goals.html). In the dialog that opens, select the goal to be run. Run Grunt task: select this option to run a Grunt task. In the Grunt task dialog that opens, specify the Gruntfile.js where the required task is defined, select the task to execute, and specify the arguments to pass to the Grunt tool. Specify the location of the Node.js runtime, the parameters to pass to it, and the path to the grunt-cli package. Run gulp task: select this option to run a Gulp task. In the Gulp task dialog that opens, specify the Gulpfile.js where the required task is defined, select the task to execute, and specify the arguments to pass to the Gulp tool. Specify the location of the Node.js runtime, the parameters to pass to it, and the path to the gulp package. Run npm script: select this option to execute an npm script. In the NPM Script dialog that opens, specify the [npm run/debug configuration settings](https://www.jetbrains.com/help/idea/installing-and-removing-external-software-using-node-package-manager.html). Compile TypeScript: select to run the built-in TypeScript compiler and thus make sure that all the changes you made to your TypeScript code are reflected in the generated JavaScript files. In the TypeScript Compile Settings dialog that opens, select or clear the Check errors checkbox to configure the behaviour of the compiler in case any errors are detected: If the Check errors checkbox is selected, the compiler will show all the errors and the run configuration will not start. If the Check errors checkbox is cleared, the compiler will show all the detected errors but the run configuration still will be launched. Disconnect Data Source: select this option if you want to disrupt the connection to a data source before the run/debug configuration is run. | | Open run/debug tool window when started | Depending on the type of configuration, open the [Run](https://www.jetbrains.com/help/idea/run-tool-window.html), [Debug](https://www.jetbrains.com/help/idea/debug-tool-window.html), or [Services](https://www.jetbrains.com/help/idea/services-tool-window.html) tool window when you start this run configuration. If this option is disabled, you can open the tool window manually:View \| Tool Windows \| Run or `Alt``04` View \| Tool Windows \| Debug or `Alt``05` View \| Tool Windows \| Services or `Alt``08` | | Focus run/debug tool window when started | Focus on the run configuration tool window when the tests are running. | | Show the run/debug configuration settings before start | Show the run configuration settings before actually starting it. |
Shard95 (laksa)
Root Hash2692805634082760095
Unparsed URLcom,jetbrains!www,/help/idea/run-debug-configuration-java-application.html s443