An in-depth guide to hosting a website using Apache Webserver


This article tells you how to download, install and configure Apache webserver on your Windows based computer to host a webpage.

Steps

  1. 1
    Go to www.apache.org and download the latest version of Apache's webserver.
  2. 2
    Install Apache.
    Advertisement
  3. 3
    In the installation process you will get a screen asking you for your domain name, network name, and e-mail address. You can add anything in these fields. Add them in this format:
    • Domain name: example.com
    • Network name: www.example.com
    • E-mail address: user@example.com
  4. 4
    Once you click Next, you will see a screen asking you what webserver this is. You can choose Apache from the radio button list.
  5. 5
    You will get an error message after telling you "Apache could not be configured." "Edit you Apache.conf file"
  6. 6
    Next go to Start-Programs-Apache HTTP server <version number>
  7. 7
    Choose "Configure Apache Server".
  8. 8
    Choose "Edit the apache.conf configuration file".
  9. 9
    Go to Document Root "drive:/location"
  10. 10
    Change the document root to point to the location of your website folder in the notion noted above using / instead of \.
  11. 11
    Do the same for <Directory "drive:/location">
  12. 12
    To test your configuration
  13. Advertisement
Method 1
Method 1 of 1:

To Restore httpd.conf

  1. 1
    If you mess up the httpd.conf file don't worry, go to your main Apache folder. Go to the conf subfolder.
  2. 2
    There you will find folder named "Original". All original files backup is present in this folder. Open original folder.
  3. 3
    Choose httpd.conf from original folder.
  4. 4
    Go to Edit-Select All
  5. 5
    Choose Copy
  6. 6
    Then go back to your current httpd.conf i.e. out of original folder. and open httpd.conf.
  7. 7
    Choose Edit-Select All
  8. 8
    Press Delete
  9. 9
    Click and paste the original text
  10. 10
    Press CTRL + S or press SAVE.
  11. Advertisement

Community Q&A

  • Question
    How do I add it on the internet?
    Community Answer
    Community Answer
    Port-forward port 80 on your router to your PC, get a free domain at no-ip.com, and link the domain to your IP.
Advertisement

About This Article

wikiHow is a “wiki,” similar to Wikipedia, which means that many of our articles are co-written by multiple authors. To create this article, 26 people, some anonymous, worked to edit and improve it over time. This article has been viewed 327,724 times.
How helpful is this?
Co-authors: 26
Updated: August 23, 2022
Views: 327,724
Advertisement