Whether you are a gamer trying to run Minecraft, a developer setting up a new environment, or simply ensuring your system is secure, knowing which version of Java you have installed is crucial. Java is a cross-platform language, but the way you check its version varies slightly depending on your operating system.
In this guide, we will show you the quickest ways to identify your Java version using the Command Line and Graphic User Interfaces (GUI).
1. How to Check Java Version on Windows
There are two primary ways to check your Java version on Windows: using the Command Prompt (fastest) or the Control Panel.

Method A: Using Command Prompt (Recommended)
- Press Windows + R on your keyboard, type
cmd, and hit Enter. - In the black window that appears, type the following command:
java -version - Press Enter.
- You will see an output similar to this:
- java version “1.8.0_281” (This means you have Java 8).
- openjdk version “17.0.1” (This means you have OpenJDK 17).
Method B: Using the Windows Control Panel
- Click the Start menu and type Control Panel.
- In the search box at the top right of the Control Panel, type Java.
- Click on the Java (32-bit) or Java (64-bit) icon.
- In the “General” tab, click the About button. A window will pop up showing your current version.
2. How to Check Java Version on macOS
On a Mac, the Terminal is the most reliable way to find your Java version.
- Press Command + Space to open Spotlight Search, type Terminal, and press Enter.
- Type the following command:
java -version - If Java is installed, the version details will appear.
- Note: If you see a message saying “No Java runtime present, requesting install,” it means Java is not currently installed on your Mac.
3. How to Check Java Version on Linux

Linux users (Ubuntu, Debian, CentOS, etc.) can use the terminal to check both the runtime and the compiler version.
- Open your Terminal (Ctrl+Alt+T).
- Type the command:
java -version - If you are a developer and want to check the Java Development Kit (JDK) version, type:
javac -version
4. Understanding the Version Numbers
Java versioning can be a bit confusing. Here is a quick cheat sheet:
- Java 8: Often displayed as
1.8.x. - Java 11, 17, 21: These are Long-Term Support (LTS) versions and will show up exactly as
11.x,17.x, etc. - JRE vs. JDK:
- JRE (Java Runtime Environment): Allows you to run Java applications.
- JDK (Java Development Kit): Needed if you want to code/develop Java applications.
5. Troubleshooting: “Java is not recognized”
If you type java -version and receive an error saying “‘java’ is not recognized as an internal or external command,” it usually means:
- Java is not installed: Download it from Oracle’s official site or Adoptium.
- Environment Variables are not set: You may need to add the Java “bin” folder to your System PATH variables so your computer knows where the program is located.
Conclusion
Checking your Java version is a simple process that takes less than a minute. Whether you use the command line or the system settings, staying updated ensures your applications run smoothly and your computer stays protected against old security vulnerabilities.
Is your Java outdated? If you saw a version older than Java 11 or 17, it might be time for an update!

SEO Optimization Keywords included:
- How to tell what Java version you have
- Check Java version Windows 10/11
- Java version command
- Check Java version Mac terminal
- Java -version command not working
- JRE vs JDK
