32

I've been using nginx without any problem on windows for the last few months. Today when I tried to start it up, I got this error:

nginx: [emerg] bind() to 0.0.0.0:80 failed (10013: An attempt was made to access a socket in a way forbidden by its access permissions)

Why did this start happening all of a sudden? I didn't change any configs or anything.

Dean Rather
  • 1,100
  • 1
  • 13
  • 18

3 Answers3

51

Check Skype.

Skype automatically updated itself, and turned the "use port 80" option back on.

It's in settions->advanced.

Dean Rather
  • 1,100
  • 1
  • 13
  • 18
  • 4
    Unbelievable, but thanks. Tools > Options > Advanced > Connection – Tom Sep 12 '14 at 12:45
  • Sneaky M$. Very sneaky. – David 'the bald ginger' Jun 08 '15 at 06:27
  • 1
    I just installed skype for web (beta). It installed a separate plugin for video, which I assume has the same behaviour. If you have a skype for web tab open in your browser, you may need to close that. – murraybiscuit Feb 29 '16 at 05:39
  • This answer only looks at Skype but there are a lot more programms that can cause this issue because of using port 80/tcp. For the easiest way see Jevgenis answer https://serverfault.com/a/478267/141615 – High Ball Oct 18 '17 at 10:17
12

Check which ports are being used on your system.

There are some programs which bind port 80. For example TeamViewer, Skype, etc.

For an easy test type http://localhost in your browser and check which service appears.

Or ou can use a programm like CurrPorts by NirSoft.

High Ball
  • 478
  • 4
  • 11
  • In my case, it was IIS blocking port 80 - this appears to be a common problem. If `netstat -o` shows PID 4 listening on port 80, that's IIS. – mindplay.dk Mar 30 '16 at 18:42
8

You can try run in CMD:

netstat -a | find "LISTENING"

also there was a piece of software called TCPView, which is very cool, and shows all runing process/occupied ports.

Jevgeni Smirnov
  • 492
  • 1
  • 6
  • 22
  • 1
    I used `netstat -ao` to also display the PID of the process blocking port 80 - then enabled the PID column in Task Manager to find out which process was blocking port 80. – mindplay.dk Mar 30 '16 at 18:40