Follow the below steps to add virtual host in XAMPP

  1. Go to C:\xampp\apache\conf\extra

  2. Open httpd-vhosts.conf file and add following lines

   DocumentRoot "C:/xampp/htdocs/{site location}"
   ServerName yoursite.local
  1. Go to C:\Windows\System32\drivers\etc

  2. Open hosts file and Add following lines       yoursite.local 
  1. Restart Apache from XAMPP window

You should be able to access your local site from browser