How to install Apache 2.0 on Windows

Warning: Abandoned
This page/script has been classified as abandoned and will no longer be updated. I will keep this page here indefinitely as a reference, but it will no longer be updated and I no longer offer support of any kind regarding content found on this page.


The tutorial below is for Apache 2.0.x and as of January 2007, I will no longer keep it updated. The current version of the Apache tutorial can be found here.

Apache 2.0.X

  1. Download & Unpack

    Download and install Apache from Look for the "Win32 Binary (MSI Installer)" version. (you might want to change the download mirror first to get better speeds)

    My file was named: apache_2.0.59-win32-x86-no_ssl.msi
  2. Install

    When you install Apache, you'll get a prompt for "Server Information." Here is the settings I used:
    Network Domain: localhost
    Server Name: localhost
    Admin Email: (your any email)
    Recommend checking: "for All Users, on Port 80, as a Service" (see Service -vs- Manual below)

    At this point if you have Windows XP with SP2, you'll get a "Windows Security Alert" about blocking incoming connections for Apache. Choose "Unblock" on the window that comes up.
    Service -vs- Manual
    Technically you should need Windows NT, 2000, or XP to run services. However, Apache2 has "some highly experimental support for similar behavior on Windows 9x" and for most people Service will work on any version of windows.
    Notes for Manual/Console users (service users ignore):
    (a) If you do install only for the Current User, on Port 8080, you will want to open httpd.conf and change Listen 8080 to Listen 80 (otherwise you will need to use http://localhost:8080/ as your address). (b) The "Monitor Apache Servers" is useless in Manual/Console mode. (c) to start Apache2 in console, go to: Apache HTTP Server 2.0.45 > Control Apache Server > Start Apache in Console. Console usually start as a blank black window. (d) To close apache in Console select the "Start Apache in Console" window and then press Ctrl+C (your "Ctrl" button, and the "C" button at same time).
    Path notes
    if you are in Setup Type: Typical and you tell it to install to:
    what it'll actually install to is:
    In Setup Type: Custom you can specifically tell it where to install each of it's parts/sub-parts.

    Also, if you are updating from a previous version of 2.x, you will have to uninstall the old version before installing the new one. However, apache 2.x will play very nicely with an older apache 1.x version.
  3. Starting/Stopping Apache

    After installing, Apache2 automatically starts. The start icon in the System Tray means it started. The stop icon means the "Monitor Apache Servers" is running, but Apache2 isn't started.

    You can easily start/stop/restart Apache and Apache2 via that icon in your System Tray. If you get "The requested operation has failed!" error while starting apache use the "Test Configuration" shortcut in the Start Menu to find the error (if the text window pops up then closes before you can read it, your config file is fine).
  4. Testing

    Now the ultimate test. To see if it's serving. Open your browser and head to: or http://localhost/

    If it shows the Test Page for Apache Installation you have your server software installed and running.
  5. Making Apache point to your files

    Using Notepad open E:\Apache2\conf\httpd.conf (in the start-menu there should also be a "Edit the Apache HTTP Server httpd.conf Configuration File" shortcut) and search for DocumentRoot. Change it from something like DocumentRoot "E:/Apache2" to the location where your HTML files and site are located. In my case: DocumentRoot "E:/public_html"
    The first time i installed Apache2, i accidentally changed ServerRoot. Make sure you change the correct line which is DocumentRoot and which is down about line 225.
  6. Then scroll down about one page and change: <Directory "E:/Apache2/htdocs"> to point to the same location you set DocumentRoot to in the last step. Restart apache to make the changes take effect
  7. Important changes when installing PHP

    These changes don't have to do with anything yet, but if you continue on following these tutorials, in the PHP tutorial on whats currently step #5 (the "Editing Apache Conf File" step), instead of the LoadModule lines it lists, with Apache 2.0 you will need to use the following lines instead (php5apache2.dll vs php5apache2_2.dll):
    	LoadModule php5_module "e:/php/php5apache2.dll"
    	AddType application/x-httpd-php .php
    	PHPIniDir "e:/php"