I keep getting the below message but I have checked and set up the path in Java: Home to the path mentioned in the below message ("salesforcedx-vscode-apex.java.home": "C:\Program Files\Java\jdk-"). I am fairly new to development so not sure how else to tackle this..

Local Java runtime ("salesforcedx-vscode-apex.java.home": "C:\Program Files\Java\jdk-") is unsupported. 
Set the salesforcedx-vscode-apex.java.home VS Code setting to a runtime outside of the current project. 
For more information, go to Set Your Java Version.

My projects are in a separate directory 'C:\Users\qbuser\Documents' so not sure why the project directory is being mentioned? Should the project not be in C:? I would also like to note that so far this has not affected my lwc development or basic apex, but they have also been basic development tasks.

2 Answers 2


I was stuck on this for a long time, but realized that I was actually entering the path in the incorrect format, partially due to the confusing SF documentation. See screenshots below.

Before I changed the format, I was getting errors for Adoptium v17, Azul v17, and even Oracle Java v11. After, I was able to get Azul v17, and even the latest Azul v19 (which the SF documentation says is unsupported) to work.

enter image description here

enter image description here

  • Thanks this worked perfectly! I am no longer getting that error message. Unfortunately I can't upvote because I'm new to this and don't have enough reputation.
    – Rahul Raju
    Feb 24 at 5:51
  • @RahulRaju I'll upvote in your stead.
    – Derek F
    Feb 27 at 14:46

The important bit of the message is this

Local Java runtime ... is unsupported.

The SFDX extensions are finding your java install, but it's complaining that it can't use Java 17.

I'm seeing a little documentation here and there suggesting that Java 17 works, but perhaps not all of the components have been updated. Java 11 is known to work, so you should install the JDK for Java 11 and use that as your salesforcedx-vscode-apex.java.home

  • Yeah I thought that could be an issue but in a Salesforce help article they mentioned that Java 17 has been tested to support so I thought this would work. Also when I visit Oracle archive it says I have to login for downloading prior versions of Java?
    – Rahul Raju
    Sep 17, 2022 at 12:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .