Follow the below steps to install Spark on Windows:
Download Spark from the official website: http://spark.apache.org/downloads.html
After Downloading, extract the compressed file, you will have a folder extracted.
Copy this extracted file to C drive.
Next step is to set Environment Variables for Spark. Search for Environment Variables in the search bar of windows and click on it. Then follow the below screenshots:
![](https://www.edureka.co/community/?qa=blob&qa_blobid=1131201397663011392)
![](https://www.edureka.co/community/?qa=blob&qa_blobid=12883333888597826892)
![](https://www.edureka.co/community/?qa=blob&qa_blobid=16091413055985796385)
![](https://www.edureka.co/community/?qa=blob&qa_blobid=14605571527996028386)
Next, download winutils from this link: https://github.com/steveloughran/winutils
Download the same version as that of Spark.
Move this file to Spark folder\bin:
![](https://www.edureka.co/community/?qa=blob&qa_blobid=14214485505167358161)
That’s it. Spark is installed. To run spark, open command prompt and run
> spark-shell
and to run Spark2, run:
> spark2-shell