How to Install Maven in Windows

In this tutorial we will see that how to install maven to the window platform. Apache Maven is not require to install on Windows as a service component, you just need to download the Maven’s zip file, extract it and configure the Windows environment path variable.

Maven is a Java tool, so you must have Java installed in order to proceed.

Tools Used :

  1. JDK 1.6
  2. Maven 3.0.5
  3. Windows 7

Step 1:  First, download Maven and follow the installation instructions. After that, type the following in a terminal or in a command prompt:

Step 2: JDK and JAVA_HOME
Make sure JDK is installed, and “JAVA_HOME” variable is added in Windows environment variable, and point to the JDK folder.
How to Install Maven in Windows

Step 3: Extract downloaded apache-maven-3.0.5-bin.zip

Extract the downloaded zip file. In this case, we extracted to F: driver and renamed the folder, e.g F:maven

Step 4: Add MAVEN_HOME
Add a new MAVEN_HOME variable to the Windows environment, and point it to your Maven folder.

Install Maven in Windows

Step 5: Add PATH
Update PATH variable, append “Maven bin folder” path, so that you can run the Maven’s command everywhere.

Maven setup in window

Step 6: Verification
Done, to verify it, in command prompt, type “mvn –version”.

C:UsersDinesh>mvn -version
Apache Maven 3.0.5 (r01de14724cdef164cd33c7c8c2fe155faf9602da; 2013-02-19 19:21:
28+0530)
Maven home: F:mavenbin..
Java version: 1.6.0_23, vendor: Sun Microsystems Inc.
Java home: C:Program Files (x86)Javajdk1.6.0_23jre
Default locale: en_US, platform encoding: Cp1252
OS name: "windows 7", version: "6.1", arch: "x86", family: "windows"
C:UsersDinesh>
maven

If you see similar message, means your Apache Maven is installed successfully on Windows.

Next

3 Comments

  1. Anonymous August 1, 2013
  2. Anonymous December 5, 2013
  3. Anonymous March 4, 2014