-
Notifications
You must be signed in to change notification settings - Fork 0
Installing Java
Installing OracleJDK (beginner recommended)
-
Both
- Maintained by Oracle
- Free to use for personal development
- Abide by the same specifications (JLS, JVMS)
-
OracleJDK
- Distributed under OTN License Agreement for Java SE
- Requires Java SE Subscription for long-term support (LTS)
- Java 8 receives LTS without subscription until end of 2020
-
OpenJDK
- Distributed under GPLv2+CPE
- Support up until a new version is released
See FAQ
-
Go to: https://jdk.java.net/
- For older versions: https://jdk.java.net/archive/
-
Choose the Ready for use JDK
-
Download the proper package under Builds
-
Extract the
.zipor.tar.gzto obtain folder -
Remember location of JDK folder.
-
Continue onto Installing OpenJDK
-
Move downloaded JDK folder to the
C:\Program Files\Java\folder- If you can't find the JDK folder, look in
C:\Users\[Your Account]\Downloads - Create the
Javafolder if needed
- If you can't find the JDK folder, look in
-
Open Environmental Variables
- On your keyboard, press
Window + Rto open the Run tool - Type in
SystemPropertiesAdvancedand hit Enter - Towards the bottom, click
Environmental Variables
- On your keyboard, press
-
Under System Variables, search for the
Pathvariable -
Double click
Pathto add a new entry -
Add the following path
- Without
OpenJDKfolder:C:\Program Files\Java\[Your JDK Folder]\bin -
Examples
C:\Program Files\Java\jdk-15.0.1\binC:\Program Files\Java\jdk-14.0.2\bin- etc..
- Without
-
Move the path to the top with the the ^ button
- If multiple paths exists, the first one (top-most) will be used
- Can move different JDK paths to the top to switch which JDK is default
-
Go to: https://www.oracle.com/java/technologies/javase-downloads.html
- For older versions: https://www.oracle.com/java/technologies/oracle-java-archive-downloads.html
-
Select your desired version
-
Go to the download page for that version
-
Choose the 64 Installer/Package
- WARNING: Choosing 64 Compressed Archive will require you to perform installation manually.
-
Use the default settings in the installer
-
Continue onto Testing Java Installation
-
Open the terminal/command prompt
-
Use the following command:
java -version
If it displayed a version, you've installed Java!