Xampp Live Server

Posted on by admin

XAMPP is a handy tool that lets you run a website from your own computer. Once you install and set it up, you can install WordPress with just a few clicks. Moreover, if you are used to developing your websites on a live server, you would be fascinated to shift to a local development environment like XAMPP. With your XAMPP installer downloaded, you are ready to open that sucker up and start installing the XAMPP server software. With XAMPP, you will be able to install all of the web server applications you need to operate your server and websites. Check this out: Add a favicon to your Website best size, best format. How To: Turn a Microsoft Windows PC into a web server with XAMPP How To: Install Joomla 1.5 on Windows with an Apache Server How To: Install XAMPP, Wordpress, and MyBB on your computer How To: Configure a XAMPP Server How To: Install a XAMPP testing server on a PC.

If you are a WordPress plugin or WordPress theme developer, or provide professional WordPress support from time to time you need to run multiple WordPress websites on the same XAMPP installation on Windows. Multiple websites running on the same Apache web server are called Virtual Hosts. In this easy to follow tutorial we explain how to setup multiple virtual hosts on XAMPP so you can run multiple WordPress websites on the same XAMPP installation.

Configure Virtual Hosts in XAMPP

  1. To add virtual hosts in XAMPP, or in other words, to configure multiple websites on XAMPP, open the Virtual Hosts Apache configuration file httpd-vhosts.conf from C:xamppapacheconfextra
  2. Uncomment the below line to enable name based virtual hosts on your XAMPP.
  1. At the end of the file add the following 4 lines. These 4 lines are used to allow access to the XAMPP configuration pages (to access phpMyAdmin etc) by using the URL http://localhost
  1. For each other virtual host (website) you would like to configure on the XAMPP Apache web server, add the below code (using www.wpwhitesecurity.com as example).
  1. By adding the above directives to httpd-vhosts.conf (XAMPP virtual hosts configuration file), the Apache web server running on XAMPP knows that:
    1. The website files can be found in c:xampphtdocswppro (line 2)
    2. This website should respond to www.wpwhitesecurity.com (line 3)
    3. Allow everyone to access the content of the directory (line 4 to 7)
  2. To test and confirm that all the syntax in the Apache configuration is correct, run the httpd.exe process with the –t switch from the c:xamppapachebin directory as seen in the below screenshot.

Configure the Windows Hosts File

Use the Windows Hosts file to redirect the traffic from your computer to the local installation of XAMPP rather than to the original website. E.g. while testing new WordPress changes for our website WP White Security.com, I add an entry in the Windows Hosts file to redirect requests from my browser to the local intallation of XAMPP. To learn on how to redirect traffic using Windows Hosts file, read our webmaster tip Configuring Windows Host Files.

Configuration example: Running multiple websites on XAMPP

If you would like to add more than one virtual host (website) to XAMPP, simple add more VirtualHost directives to the same file. In my testing environment I have the following websites set up:

  • www.WP White Security.com from c:xampphtdocswppro
  • www.wphandymen.com from c:xampphtdocswphandy

To have both websites and the XAMPP configuration pages (localhost) running on my XAMPP installation, I have the following in the XAMPP virtual hosts configuration file (httpd-vhosts.conf).

If you would like your computer to be a local web server for website development, then this tutorial is for you. This is easily accomplished by installing the cross-platform, free XAMPP Lite software package.

This tutorial provides clear, step-by-step instructions on how to install, setup, and use XAMPP Lite on a Windows PC. It also discusses some other considerations when using XAMPP.

Xampp Server For Windows 10

○ This tutorial contains affiliate links. Read our disclosure policy to learn more. ○

What is XAMPP?

XAMPP, a free, open source software package produced by the non-profit organization Apache Friends, is the most popular web server software package used for website development. XAMPP is (X) cross-platform, and, at minimum, contains the (A) Apache HTTP server, and supports the (M) MySQL database, (P) PHP scripts, and (P) Perl scripts. XAMPP distribution packages are available for Windows, Linux, and OS X system operating environments.

Website Server Overview

New webmasters coding primarily in HTML should choose a UNIX-based website hosting plan. The host company provides disk space on a server which holds your website documents, images, and scripts. The root directory is the top-most folder of your allocated disk space and is typically named public_html, or www, or htdocs. Your website's homepage - usually index.html (or .shtml or .htm) - must be stored in the root directory. Usually the other webpages which link to the homepage are also stored in the root.

About 70% of the webpages on the Internet are handled by Apache HTTP servers in a UNIX (Linux) environment. When an Internet user requests a website via its URL (e.g. http://www.mysite.com), the Apache HTTP server looks for the 'index' file in the root directory for that website and sends this homepage to the user's browser to render (display).

Website Testing


A website should never be uploaded to the 'live' server until all of its webpages have been thoroughly tested on the most popular browsers. This testing can be done on a local PC using the Apache HTTP server component of the XAMPP package. Your PC can act as a web server even when it's not connected to the Internet!

Your website hosting company should provide cPanel (Control Panel) or another user interface for accessing disk space and performing administrative functions. Even though you can usually use this interface to upload website files, serious webmasters should upload files using a File Transfer Program. There are several good - and free - FTP programs available, such as FileZilla.

Xampp Live Server

Downloading XAMPP Lite

To download XAMPP, go to the Apache Friends XAMPP webpage. Click on XAMPP for Windows. From the XAMPP for Windows page, find XAMPP Lite. Click on the EXE file and download it to your hard disk.

Xampp Live Server Status

The developers of XAMPP Apache are no longer creating a 'Lite' version. The last version of XAMPP Lite, version Win 32 1.7.3, can be found on XAMPP's webpage on sourceforge.net. The executable file is 'xampplite-win32-1.7.3.' For the program list and release levels, click the 'i' by the file and then click 'Release Notes.'

We have successfully installed this version of XAMPP Lite on a Windows 7 PC. However, your Windows 7 computer is not our computer nor have we installed the software on newer releases of Windows. Since this software was built in 2009, you are using this software at your own risk. This tutorial has helped a lot of folks over the years and we keep it here for archive purposes, but see links in the last paragraph. Now to the tutorial.

Installing XAMPP Lite

Before installing any new software, create a System Restore point in Windows. If you need help, read our tutorials found on the Windows menu tab.

Close all programs. Locate and double-click the XAMPP Lite file that you just downloaded. Take the default install options. (Some problems have been reported if the product is installed in a different directory).

The program will quickly install. When completed, a XAMPP program shortcut is placed on the desktop.

If you are installing XAMPP Lite on Windows 7, you may receive the following message that we did recently when installing xampplite-win32-1.7.3.exe. A black box appeared on the desktop labeled 'C:Windowssystem32cmd.exe' and displayed a series of questions. The questions, and our responses in red (often taking the default and just pressing Enter), are shown below. Modify as necessary:

  • Should I add shortcuts to the startmenu/desktop? (y/n) y [Press Enter].
  • Should I locate the XAMPP paths correct? Should I proceed? (y/x=exit setup}: y [Press Enter ].
  • Should I make a portable XAMPP without drive letters? ... Your choice? (y/n): n [Press Enter].
  • XAMPP is ready to use ... Press (Return) to continue. [Press Enter].
  • The time zone has been set to EST ... Press {Return) to continue: [Press Enter].
  • The next message presents six options: #1 through #5, or x. We choose 'x' because we wanted to start XAMPP by clicking on the desktop shortcut. So type x (or your choice) and press Enter. The black box should disappear.

Customizing XAMPP Document Root (Where Website Files are Stored)

The default folder for storing your website documents is located inside the installation folder 'xampplite' or 'xampp.' Most folks prefer to change the location to a more convenient folder. Follow the directions below to change the default folder to one named 'Apache Sites' on the C-drive.

  1. Create a new folder on the C drive named 'Apache Sites.'
  2. Open Notepad. (Click Start All Programs Accessories Notepad)
  3. Click File Open. From the 'Look in:' box, click the C-drive and double-click the XAMPP installation folder.
  4. Double-click the 'Apache' folder and double-click the 'conf' folder. Then, at the bottom of the Open window, change the filetype to 'All Files.'
  5. Right-click on 'httpd.conf' and click Copy. Then click in a blank area of the small window and right-click Paste. (This is your backup if you mess up.)
  6. Now, double-click 'httpd.conf' to open it in Notepad.
  7. Click Edit Find, and move the little Find box to the right side of the window.
  8. Type in DocumentRoot and click Find Next TWICE. Your cursor should rest on a line that specifies the document root as follows: Document Root: 'C:xampphtdocs' - or - Document Root: 'C:xampplite htdocs'
  9. Carefully edit this line by typing Apache Sites after C:/ so that the entire line reads: DocumentRoot 'C:/Apache Sites' ... don't delete the ending quotation mark.
  10. Go back to the top of the file and click at the top of the page so the cursor is at the beginning of the file. Open the Find box if not still visible and type <Directory and click Find Next TWO TIMES. The line above where your cursor should now be located says 'This should be changed to whatever you set DocumentRoot to.'
  11. On the line where your cursor rests, type Apache Sites after C:/ so that the entire line reads <Directory 'C:/Apache Sites'> ... don't delete the ending quotation mark or greater-than mark. Cancel the Find box.
  12. Click File Save, and exit out of the Notepad document.

Starting and Stopping the Apache HTTP Server

To start the Apache server, double click the XAMPP program shortcut that was placed on the desktop. Then click Start for Apache.

Windows Firewall may display a window that says 'Windows Firewall has blocked some features of this program.' Check the box next to 'Private networks' and un-check the box next to 'Public Networks.' Then click Allow access.

Once the program says 'RUNNING' you can close the Apache window by clicking X in the upper right corner.

Using XAMPP as a local server

You do not have to be on the Internet to use the XAMPP server. The Apache HTTP Server component of XAMPP allows your PC to act as a web server. Open a browser window and type http://localhost in the URL box. With some browsers, such as Firefox, you can just type localhost. The contents of the Apache Sites directory (the folder you created above) will display. If you do not see the 'Index of /' at the top of the webpage and Apache is definitely running, try typing in the URL box. If this works, then 'localhost' is not defined in your Windows Host File. (Instructions for fixing this are available on the Internet.)

Individual HTML files may be placed in the Apache Sites folder, or a folder can be created inside of the Apache Sites folder for each unique website you will be working on.

When you click on an HTML file in Apache Sites, the webpage should display in the browser window. If you click on a folder, Apache will display the index or homepage file inside of that folder.

Conflicts Apache May Have With Other Programs

The Apache server expects to use Port 80 on your computer. If another program is using Port 80, you may receive errors when first starting Apache. For instance, Skype uses Port 80. However, it is easy to change the port number for Skype to eliminate the conflict. Open the Skype application. Then click Tools Options Connections, and remove the check mark by PORT 80.

Microsoft IIS (Internet Information Services), a competing web server program, also uses Port 80. IIS is not installed on most Windows systems by default, so this won't affect most new webmasters.

Alternately, you can change the port that Apache listens to by modifying the httpd.conf file, locate the line that specifies 'Listen 80' and change it to 'Listen 8080.' However, instead of typing localhost (or http://localhost) in the URL bar as described below to access your websites, you will have to type localhost:8080. This shouldn't be a big problem if you create a bookmark for the page in your browser.

Security and Apache XAMPP

Xampp Live Servers

The product XAMPP is meant to be used in a development environment, not a production environment. As such, it does not have proper security if others can access your computer. Therefore, it is essential to ensure that the XAMPP machine is not accessible to others on the Internet or private network by using a Firewall and other security measures, if necessary.

Other Potential Problems

The Apache website has a special section on XAMPP for Windows FAQ. Some of the topics covered are: not enough system memory, XAMPP will not start, XAMPP using 99% of CPU resources, MySQL, and images and style sheets not displaying properly.

Occasionally an anti-virus program will find false positives that are really files in legitimate programs. The Apache website states that over the years some anti-virus software has had trouble will files such as 'kill.exe' ... 'pv.exe' ... or 'xampp-control.exe'. The providers of XAMPP claim it is free of viruses and spyware, and our experience has shown this to be true.

If you are having problems or cannot find the information you are looking for in the documentation that comes with the software, check out the Apache Friends Support Forum.

How To Configure Xampp Server

We hope our tutorial on the install, setup, and use of XAMPP Lite has been helpful. Cheers!

↑ Return to the top