Java can be downloaded for free from the following web site:
Step 1: Install Java (from Oracle)
Step 2: Install IDE
Once you have Java installed, you should download an GUI Integrated Development Enviornment (IDE) to code and develop in. There are numermous options. Below are several.
If you just want to run or test a small Java program, you can use an online web site.