How to Resolve the STS Launch Error: Java Was Started but Returned Exit Code=13?

Question

What does it mean when STS launch fails with the error 'Java was started but returned exit code=13'?

Answer

The error 'Java was started but returned exit code=13' when launching a Spring Tool Suite (STS) usually indicates a problem with the Java environment setup or compatibility issues between the Java version and STS. This guide will help you understand the causes of this error and how to resolve it effectively.

# Example STS.ini modification
-vm
C:/Program Files/Java/jdk1.8.0_201/bin/javaw.exe

# Make sure to replace the path with your Java installation path.

Causes

  • Incompatible Java Runtime Environment (JRE) version installed
  • Incorrect Java version set in STS configuration
  • Java installation corrupted or incomplete
  • ST-based application and Java bit-version mismatch (e.g., 32-bit vs 64-bit)

Solutions

  • Ensure that you have the compatible version of Java (JDK) installed that matches the STS version.
  • Update the STS configuration to point to the correct JDK by modifying the 'STS.ini' file to include the path to the correct JDK installation.
  • If you're facing bit-version issues, ensure that both STS and Java are either 32-bit or 64-bit versions.
  • Reinstall Java to fix any potential corruption or missing files in the installation.

Common Mistakes

Mistake: Not checking the bit-version compatibility between STS and Java.

Solution: Always ensure that the bitness of the Java version matches that of the STS.

Mistake: Modifying the STS.ini incorrectly or omitting necessary parameters.

Solution: Carefully edit the STS.ini file and include the JVM path without altering other necessary configurations.

Helpers

  • STS launch error
  • Java exit code 13
  • Spring Tool Suite error
  • Java compatibility issues
  • STS configuration fix

Related Questions

⦿How to Build an Algebra Equation Parser in Java

Learn how to create a robust algebra equation parser in Java with detailed steps and code examples.

⦿How to Handle Casting with Java Generics Interfaces

Learn how to effectively work with casting in Java Generics interfaces including common mistakes and best practices.

⦿How to Check for Null or Empty Values in StringBuilder in C#

Learn how to effectively check for null or empty values in StringBuilder in C with examples and best practices.

⦿How to Convert RGB Color to CIE Lab in Java

Learn how to accurately convert RGB colors to CIE Lab color space using Java. Stepbystep guide and code samples included.

⦿What is the Purpose of an Empty Code Block with Just Curly Braces in Java?

Discover why Java allows empty code blocks and their potential use cases in programming. Learn more about code structure and clarity.

⦿How Can I Detect When the Search Button on the Keyboard is Pressed in JavaScript?

Learn how to easily detect keyboard search button presses using JavaScript for enhanced user input handling.

⦿How to Resolve 'Connection Cannot Be Cast to oracle.jdbc.OracleConnection' Error in Java?

Learn how to fix the Connection cannot be cast to oracle.jdbc.OracleConnection error in Java with detailed explanations and solutions.

⦿How to Create a Regex Pattern to Match Java Method Declarations

Learn how to construct a regex pattern to match Java method declarations effectively with examples and best practices.

⦿How to Delete Oldest Entries from a HashMap to Maintain a Specific Size?

Learn how to efficiently manage a HashMap by deleting the oldest entries to maintain a specified size with practical examples and techniques.

⦿How to Troubleshoot Firefox Not Opening with Selenium WebDriver

Learn how to fix issues with Firefox not opening when using Selenium WebDriver. Get effective solutions and coding tips.

© Copyright 2025 - CodingTechRoom.com