Skip to content

SIP 502 Bad Gateway

What SIP 502 means

A proxy passed your call on and got back something it could not use. It points at the link between your provider and the network beyond it, so DNS and trunk host configuration are the places to look.

What SIP 502 Bad Gateway actually means

The server, acting as a gateway or proxy, received an invalid response from the downstream server it consulted while trying to fulfil the request. It is reporting a problem one hop further along than itself, which is why the fault is rarely in the device that receives it.

What causes SIP 502 on a business phone system

How to fix SIP 502

  1. Check the trunk host and DNS recordsConfirm the SIP domain and outbound proxy match current provider documentation, and that they resolve to the addresses the provider expects.
  2. Disable SIP ALGWorth eliminating here as everywhere else, since a mangled response can be rejected as invalid.
  3. Raise it with your provider with a Call-IDA 502 usually describes a problem beyond your network edge, so it needs their logs.

Fixing the underlying problem

This page explains the code. These guides walk through the fix in detail.

Questions about SIP 502

What does SIP 502 Bad Gateway mean?
A proxy handling your call asked the next server along and got back a response it could not use. The problem sits one hop beyond the device that reported it, which usually means between your provider and the carrier.

Call hangup causes that become SIP 502

If the call crossed a gateway between SIP and ISDN or SS7, this status may have started life as one of these Q.850 cause values. The mapping is defined in RFC 3398 section 7.2.4.1.

Related SIP response codes

Source. SIP 502 Bad Gateway is defined in RFC 3261 section 21.5.3 and registered in the IANA SIP Parameters — Response Codes. The causes and fixes above are drawn from our own experience supporting UK business phone systems.

All VoIP & SIP codes

Sitemap