Trying to use IntelliJ 12.0.2 on MAC, Where is my SDK?

Trying to use IntelliJ 12.0.2 on MAC, Where is my SDK?

If I do a javac -version I get the following output
javac 1.7.0_11

But I dont know where the SDK is install on a MAC!  Can someone please help me


I'm not a mac person, but if you run the command (at the command line)

which javac

it should report where java is installed. Hopefully a Mac user will come along and give you more detail.


It was not that easy but I will update it over the weekend



which javac

will always end with following result:


which is only a link to:


where "Current" is also a link... so it's hard to find out where is JRE/JDK installed.
It's really complicated (no idea why) how JRE/JDK installation looks like on Macs.


Should be in the following location:


Should you need to use JDK 1.6... well, it depends:

  • update 37 or newer (don't think there's newer yet) is located (similar to 1.7) in:


  • update earlier than 37 is located in somwhere else, don't remember it right now :)

There's quite good article explaining all the magic about JDK install locations, paths and variables here:


Please sign in to leave a comment.