Before you can install ANT, please make sure that you have installed the JDK 1.5 and above.
Download the ANT application file in ZIP from http://ant.apache.org/bindownload.cgi


Extract the file into the C:\apache-ant-1.7.0

Configuration of the ANT path
Go to My Computer-> Right Click -> Properties

Click on the Advanced Tab and continue to the Environment Variables

To set the ANT and JAVA path, click on NEW button under SYSTEM VARIABLE.
Type Variable Name: ANT
Variable Value: C:\apache-ant-1.7.0

Click OK
Click on New Button once more time to create the JAVA PATH
Variable Name: JAVA_HOME
Variable Value: C:\Program Files\Java\jdk1.6.0_13

Click OK

Find variable PATH in the below portion of the System Variable and click EDIT.
Add in the %ANT_HOME%\bin; under the variable value.

Click OK and you're finished.
Testing the ANT
Click on Start-> Run -> cmd -> ant -version
If the ANT is successfully configured, it will return :
Apache Ant version 1.7.1 compiled on June 27 2008