When I am writing this blog, the MAVEN version is 3.5.2. This blog is relevant to install current latest version on Windows 10.
Note – Maven 3.3+ require JDK 1.7 or above to execute.
Install JDK 1.7 or higher on your operating system
Set JAVA_HOME system variable added as windows environment Variable.
Download Apache Maven
Unzip the file in the desired location. In my case unzipped to this folder – C:\install\apache-maven-3.5.2
Set M2_HOME system variable added as windows environment Variable. Point this vairable to unzipped maven location. In my case, it is C:\install\apache-maven-3.5.2
Update PATH Variable
Update Path System variable in environment variable list to include %M2_HOME%/bin folder.
Open your command prompt and run “mvn -version”. You will see Apache maven version along with Maven and java home details.
Congratulations you have successfully configured Maven on your Windows operating system.
Reference – http://maven.apache.org/download.cgi