Setting up Wamp Server in Windows 8

Have you ever tried installing WAMP Server on your brand new Windows 8 ? If you have I am sure you have found WAMP crashing OR your

access to localhost has been forbidden. 

The reason why it happens is IPV6. Windows 8 is by default an IPV6-first Operating System. How? Well just go to command-prompt and run the command

ping localhost  

You will be getting response from ::1 i.e. the loopback address for IPV6. When you try to connect to the server it uses the port 80 along with IPV6 to locate it.

WAMP by default runs on IPV4 and it is not configured to run on IPV6. This creates a conflict in the server configuration. What you should do is open the file…

your-wamp-installation-folder\bin\apache\Apache2.2.21\conf\httpd.conf   e.g.  C:\wamp\bin\apache\Apache2.2.21\conf (In my case)

Find a line that says Listen 80 and replace that with Listen

Go to your hosts file that is located at C:\Windows\System32\drivers\etc folder and edit the file using Administrator Rights. Make sure the line ::1 localhost is commented and localhost is uncommented or add a line if it does not exist.

Thats all. Restart WAMP Server and everything should work fine.

About these ads

37 thoughts on “Setting up Wamp Server in Windows 8

  1. cool this is the solution, the wamp server icon is green but still say is offline but working, something important to edit the hosts file I did use HOSTSMAN great tool to do it,

    • the meaning of offline in wamp means something else. When wamp is online, it means it can accept requests from all ip addresses denying no one. when offline, it denies everything other than localhost. and for me notepad is just fine to edit that.

  2. thanks a lot… its wrking on my win8…before it ,i was thinking to reinstal win7…..but u save me from this trouble……

  3. Wow, total lifesaver! I was pulling my hair out over this one. I only wish that this would have been at the top of my search results, would have saved me a lot of trouble. Thanks for the info.

  4. I am trying to install the wordpress with the wamp, and I have done all of this part above. However, when i create the database wordpress and I then go to set it up I have the right database name, just it is saying ‘cant select database’ Can you help me with this?

    • are you sure your database settings in config file are ok? or the database name that you are providing? a quick googling gives a lot of known reasons why this might be happening…

  5. Thank you! Thank you! Thank you! I tried your solution a couple of times, and couldn’t get it work, and I was thinking, “This answer is sh*t….⌐_⌐. It’s not working at all…”. And then I realized that you said you have to “Restart WAMP”, and then I did that, and it worked. ^_^” lol

    Anyway, thanks a lot for the great info.! Bookmarking!! ;)

  6. I opened the file in conf folder, it’s not allowing me to change anything in that file…it’s httpd.conf..Help!

  7. I did all of this and dont working, icon isnt green and localhost page is blank, port is used by system?

    What to do?

    • can you tell me if you have skype installed or not? if so, skype occupies that port. so you gotta close it completely before you work with apache or change your port to something else other than 80

Your Comments :

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s