Those who are unfamiliar with how web pages are delivered to a browser might also be surprised to learn that the most popular software which performs this task, namely Apache, is completely free and can be used on one’s personal computer, even without hosting a website. The reasons for doing so might not be apparent, but web developers commonly do this for staging purposes, before uploading to a live server. To begin, there are some basic concepts that may be helpful for novice users to appreciate the purpose and use of a web server.
Introduction to Webservers
If a computer running a web server such as Apache isn’t specifying a domain name, like whatever.com, it can be displayed in a browser by the customary default called localhost. Thus, by entering the url http://localhost/ into a browser the web pages being served by the local machine can be viewed.
Installing Apache as a Stand Alone Application
In order to download Apache, go to their website and navigate to the Download from a mirror area. The latest is 2.4.25 (don’t get the alpha which may be buggy because it’s obviously still in development). The simplest one for Windows users is the Win32 MSI version without crypto (no mod_ssl). The installation wizard provides a step by step process that makes an otherwise complicated task quite simple.
On the Server Information screen, for the Administrator’s Email Address field put in any email address and choose Port 80, as a service so that way it will come up automatically when the computer is started up. For Setup Type, select Typical. From the Ready to Install screen, click on the Install button to initiate the final installation process. Upon completion, click on the Finish button.
Type in http://localhost/ into a browser to check that it is working properly. Last but not least, modify the index.html file with a text editor like Notepad, in the htdocs directory, to make changes to this page. Use HTML to customize and experiment with it and make additional HTML pages as desired.
Installing Apache as Part of a Software Bundle
An alternative method of installation is to use the LAMP, WAMP or MAMP solution stack, which bundles Apache with MySQL and PHP (The L stands Linux, W for Windows and M for Mac respectively). MySQL is a popular open source database and PHP is a scripting language, commonly used to work together with Apache for making dynamic web applications.
To configure Apache using a front end GUI interface try ApacheConf, which is not dissimilar from Microsoft’s IIS web server console. The installation wizard is very simple and easy to use. The lite version is free or upgrade to the Pro Version, which is $75 for a personal license or $290 for a company license.