API via Web: use 80 port or a custom one (like 8080)?

http, java

Solution

If some of your clients are behind a firewall they may have policies that restrict access to 'non-standard ports', including port 8080. Apart from that I do not see any cons to running your web service endpoints on port 8080. A pro is that if you want to run a regular web server on the same machine you can assign it port 80 with no conflicts.

Moving the service to another port doesn't increase your security risk any more than having it on the original port. Running on port 8080 shouldn't affect any mobile devices, as long as their ISP doesn't block the port.

Problem

We have a web service that won't be accessed by human users. I.e. only by: - Javascript from a browser - Mobile applications (iPhone & Android) - Other servers The question: is it OK to use some custom port for this (like 8080) or we should use only 80 port (so the URL won't contain the port number). What are the pros and cons? Are there any reasons why the option with custom ports is unacceptable?

Original source