What port does RabbitMQ use?
RabbitMQ uses port 5672 over TCP.
| Port | Protocol | Name | What it is for |
|---|---|---|---|
| 5672 | TCP | AMQP / RabbitMQ | Message broker protocol. |
What catches people out
The default guest/guest account only works from localhost, but people disable that. Do not.
Checking it is listening
sudo lsof -i :5672 # macOS, Linux
netstat -ano | findstr :5672 # Windows
nc -zv host 5672 # from elsewhere
An "address already in use" error on a port nothing appears to be holding usually means the socket is in TIME_WAIT rather than that a process has it — the ports reference covers that and the ephemeral range.
Frequently asked questions
What port does RabbitMQ use?
RabbitMQ uses port 5672 over TCP. Message broker protocol.
What should I watch out for with port 5672?
The default guest/guest account only works from localhost, but people disable that. Do not.
How do I check whether RabbitMQ is listening?
sudo lsof -i :5672 on macOS or Linux, netstat -ano | findstr :5672 on Windows. From another machine, nc -zv host 5672 says whether anything answers.