Setup virtual hosts using xampp

Here i am going to give you step by step instructions to setup virtual hosts using XAMPP on windows machine.

As we know wordpress is widely used to create multisite and it’s very easy to create multisite using wordpress.

Virtual hosts is very useful to run wordpress multisite in your localhost server.

Follow below steps to setup virtual hosts

1.First you need to install XAMPP, you can download it from here Click here to download XAMPP.

2.Go to your XAMPP installed directory and then navigate here C:/xampp/apache/conf/extra , as my XAMPP installed in C: drive .May be it’s your different drive.

3.Open this file httpd-vhosts.conf.

4.Uncomment this line # NameVirtualHost *:80 by removing hash.

5.After that add below code:

6.Then you need to setup your project directory and server name for your project, add below code for this and save it:

7.Now you need to edit your windows hosts file for this navigate here: C:/Windows/System32/drivers/etc/hosts.

Then find this line localhost

Then point your site like this: mysite.devgang

Now save your hosts file.

Now you finished your setup , restart your XAMPP apache server.

Open browser and access your site like this: mysite.devgang

Cheers 🙂

Gaurav Kumar

Hi, my name is Gaurav Kumar and I specialize in Computer Software industry. I have been working as a Software Developer from last 3+ years,and its my passion to learn new technology and sharing what I've learned.