Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I use Xampp to give me a localhost environment for testing PHP. I recently set up a virtual host in the httpd-vhosts.conf file of xampp so that I could seperate projects into their own domain name space - my virtual host description is below:

NameVirtualHost *
<VirtualHost *>
    DocumentRoot "C:\xampp\xampp\htdocs"
    ServerName localhost
<VirtualHost *>
    DocumentRoot "C:\xampp\xampp\htdocs\sales_dev2"
    <Directory "C:\xampp\xampp\htdocs\sales_dev2">
        Order allow,deny
        Allow from all
<VirtualHost *>
    DocumentRoot "C:\xampp\xampp\htdocs\opencart"
    ServerName opencart.local
    <Directory "C:\xampp\xampp\htdocs\opencart">
        Order allow,deny
        Allow from all

I also edited my hosts file so that each of the ServerName's described would resolve to

This setup works fine in FireFox and IE, but in Chrome the ServerName's that do not follow a recognised TLD are instead resolving to a google search for that string (google search 'opencart.local' for instance)

Can anyone please advise on how to resolve this?

share|improve this question
This is related to: chrome-does-not-follow-hosts-file – arober11 Jan 17 '13 at 18:49
looks like a duplicate of… – Ivar Jan 29 '13 at 21:08

you can type .dev at the end of your Vhost name. it will be solved and google never search anything.

and also type following ip in your host files.(may work, not sure) ::1 yourvhost

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.