There are times that you might want to check which service or application is current using port 80 in windows. For me, this morning, I intended to start up grizzly server to test comet streaming server, however, there is an exception thrown.

java.net.BindException: Address already in use: bind: 80=com.sun.grizzly.http.SelectorThreadHandler@15c7850
at com.sun.grizzly.TCPSelectorHandler.initSelector(TCPSelectorHandler.java:446)
at com.sun.grizzly.TCPSelectorHandler.preSelect(TCPSelectorHandler.java:393)
at com.sun.grizzly.SelectorHandlerRunner.doSelect(SelectorHandlerRunner.java:183)
at com.sun.grizzly.SelectorHandlerRunner.run(SelectorHandlerRunner.java:130)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)

The exception is quite easily to understand or guess. The port80 is already in use and grizzly simply can’t listen on the 80. Previously I met this problem as well. And when I type “localhost” in the browser address bar, it returns me the IIS default page. So I knew that the problem is IIS.

So I just needs to go to control panel and stop IIS server. However, this time, when I type “localhost” in the browser address bar, it returns me an empty page. Which means that there is indeed some program open my port 80 however, there is no index page to display. If the port 80 is no open and you type “localhost”, the browser should tell you that it is not able to connect to the server. So the next step is to find out which process is taking up my port 80. In ‘cmd’ window, type the following command:

netstat -o -n -a | findstr 0.0:80

So this is what it returns on my computer:

C:\Users\Shanison>netstat -o -n -a | findstr 0.0:80
  TCP    0.0.0.0:80             0.0.0.0:0              LISTENING       7108
  UDP    0.0.0.0:80             *:*                                    7108

netstat -o option is to list the PID (process ID), so I know that the process with PID 7108 is listening on port 80. Now, go to task manager and search the process with PID 7108.

From the screen shot, we know that TVU is taking up port 80! TVU is a video streaming software. If you are searching for a free software to watch FIFA 2010 now, which almost comes to an end, you might try this software. From this, we also know that TVU is a P2P software. When you start up the program, it opens port 80 and behaves as a webserver to upload data.

24 Responses to “How to check which application is using port 80 in windows”

  1. Eliran says:

    Tnx for the great guide.

    :)

    keep it up.

  2. anamaria says:

    my cmd is not returning any details :(

  3. Larry says:

    Hi

    Perhaps you can help me solve a silly problem. I am running a web server on an XP PC and cannot access it from a computer outside my domain. Within my domain it works fine (run “hello.html” to check). The DNS works fine and I forwarded port 80 in the router. I also checked Windows firewall and made port 80 an exception. I checked Port 80 with nmap and it is open.

    Can you give me any suggestions to analyze this.

    Thanks.

    Larry

  4. Mubasher says:

    Hi

    It was really really really helpful .

  5. shobhit says:

    hi, i am having a problem to install wamp server on window 7, we install the wamp server correctly but when i wamp icon the icon is orange not to get green color, and my apache server is showing offline. and i do above process netstat -o -n -a | findstr 0.0:80 in cmd, the result is
    TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 4
    and no any pid is start number 4 how to find pid 4 and stop this process….

    • shanison says:

      Hi it has been a few years since I used wamp servers on windows. I am working only on linux servers now. Many things might changed for wamp so I can’t really advise you how to solve the issues, but checking the logs file for wamp would be a great choice to see what’s going on?

  6. Spinx says:

    I got a problem where NT Kernel & System was take over the port 80 , but I had to start Apache which is need port 80 , need solution pls ? ><

  7. Nels says:

    This is great guid. It works for me. Thanks!

  8. eric says:

    strange i got this result TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 4
    but can’t find that 4 value on windows task manager

  9. Kevin says:

    Hey when I typed in at cmd netstat -o -n -a I got a process with local adress 0.0.0.0:80, but when I look at task manager I can’t find it

    • shanison says:

      Have you tried clicking on “Show processes from all users” on the task manager?

      • Asad says:

        No i cant find.. i also try “Show processes from all users” ..
        but no result….
        cmd say 80 port listining is pid 3860,,
        but it is not in task manager,,,

  10. Amit Jog says:

    Hey shanison…
    Thanks a ton..

    Amit

  11. DNguyen says:

    Thank you. Your post is very helpful.

  12. Saquib says:

    U are AWESOME man!!! :)

  13. Harsh Mehta says:

    Awesome. Stupendous. Thanks,

  14. Roger Whittman says:

    Very often, you will notice process ID “4” taking port 80. You will need to stop service “web deployment agent service”. It will resolve it.

  15. chukwuemeka says:

    nice post, really helped. thanks

  16. lawrence says:

    Very good article. It helped me a lot. thanks.

  17. AhmedM says:

    thank you very much
    this very good idea and it worked
    the problem was the previous Apache app it is process not stooped before deleting

  18. Atul Mahajan says:

    Sir pl tell me that how I can check port 80 is used for which site with date and time & duration.

Leave a Reply

Your email address will not be published. Required fields are marked *