PBX configuration

This guide covers the settings required to connect your own PBX to a Dial 9 SIP trunk.

Before configuring your PBX, make sure you have created your trunk in Dial 9 Connect and routed your numbers to it. See Setting up a SIP trunk for those steps.

Quick reference

Setting IP address trunk Username and password trunk
SIP server sip.dial9.co.uk sip.dial9.co.uk
Authentication IP address Username and password (SIP digest)
SIP transport UDP UDP
SIP port 5060 5060
SIP registration Not required Required
Username/password Not required Shown on your trunk in Dial 9 Connect
Number format E.164 without the + symbol E.164 without the + symbol
Caller identity Always send P-Asserted-Identity Always send P-Asserted-Identity

Dial 9 identifies an IP address trunk using the public IP address of your PBX, so your PBX does not need to register or authenticate. A username and password trunk is identified by the username your PBX authenticates with, so it can connect from any address.

Firewall configuration

Your firewall must allow SIP signalling and RTP media between your PBX and the Dial 9 network.

See our Firewall rules guide for the current Dial 9 signalling addresses, media ranges and required ports.

If SIP signalling works but calls have no audio, one-way audio, or disconnect shortly after being answered, firewall or NAT configuration should be one of the first things you check.

Registration

This section applies to username and password trunks only.

Register your PBX with:

sip.dial9.co.uk

Use the Username and Password shown on your trunk in Dial 9 Connect. Enter the whole username, including your phone system's prefix, for example harbourit-r7tw3hbn.

Dial 9 sends incoming calls to the address your PBX last registered from, so keep the registration refreshed. If your PBX is behind NAT, make sure it sends keep-alives so the registration stays reachable.

If you regenerate the password in Dial 9 Connect, the old password stops working immediately. Update your PBX straight away.

Incoming calls

When a number's destination is set to Send to a trunk in Dial 9 Connect, we send its calls to your PBX:

  • IP address trunks: to your PBX's IP address on port 5060, from the Dial 9 signalling addresses listed in our Firewall rules guide;
  • username and password trunks: to the address your PBX registered from.

Each call carries its numbers in E.164 format without the + symbol:

Header Contains Example
Request URI user The number that was dialled 441202912444
To user The number that was dialled 441202912444
From user The caller's number 447777123456
P-Asserted-Identity The caller's number, when your phone system is set to send it 447777123456
Privacy id, only when the caller has withheld their number id

Your PBX should therefore have an inbound route capable of matching the dialled number in this format.

If your PBX asks Dial 9 to authenticate calls it sends to a username and password trunk, Dial 9 answers using the trunk's username and password.

Connection checks for IP address trunks

We send a SIP OPTIONS request to each IP address trunk every minute. Your PBX must reply to it, and the trunk shows as online in Dial 9 Connect while it does. Make sure your firewall allows these requests.

Numbers using a SIP URL (now deprecated)

If a number still uses a SIP URL as its destination, we send its calls to the SIP server in that URL, using the URL's username as the destination user.

For example, if your SIP URL is:

01202912444@1.2.3.4

Dial 9 will send calls for that number to your PBX at 1.2.3.4, using 01202912444 as the destination user. Configure your PBX to match that exact value.

SIP servers and SIP URLs are now deprecated. We recommend moving these numbers to Send to a trunk.

Outbound calls

Send outbound calls to:

sip.dial9.co.uk

For an IP address trunk, calls must originate from the public IP address configured on your trunk in Dial 9 Connect. SIP registration is not required.

For a username and password trunk, your PBX must be registered. Dial 9 asks your PBX to authenticate each call, and it should answer using the trunk's username and password. The From header can carry your Dial 9 number, because the trunk is identified by its username.

Dialled number format

We recommend sending destination numbers in E.164 format without the + symbol.

For example:

UK landline:

441202912444

UK mobile:

447777123456

For UK numbers, this normally means removing the leading 0 and replacing it with 44.

For example:

01202 912444 → 441202912444

07777 123456 → 447777123456

Outbound caller identity

Your PBX should always send a P-Asserted-Identity header on outbound calls.

The P-Asserted-Identity header should contain the telephone number that identifies the calling party on your Dial 9 service, in E.164 format.

For example:

P-Asserted-Identity: <sip:441202912444@your-pbx.example.com>

You should also send an appropriate From header:

From: <sip:441202912444@your-pbx.example.com>

In most straightforward configurations, the number in From and P-Asserted-Identity will be the same.

Why P-Asserted-Identity matters

P-Asserted-Identity provides a clear network identity for the call independently of the From header.

This is particularly useful in more complex call flows, such as forwarded calls, where the contents of From may not always represent the number associated with the Dial 9 service.

Although Dial 9 does not currently enforce the presence of P-Asserted-Identity on every outbound call, PBXs should always send it.

This provides more predictable behaviour and avoids relying on fallback handling based on other SIP headers.

Example outbound INVITE

A simplified outbound SIP request might look like:

INVITE sip:442071234567@sip.dial9.co.uk SIP/2.0
From: <sip:441202912444@pbx.example.com>
To: <sip:442071234567@sip.dial9.co.uk>
P-Asserted-Identity: <sip:441202912444@pbx.example.com>

In this example:

  • 442071234567 is the destination number.
  • 441202912444 identifies the calling party.
  • The call is sent to sip.dial9.co.uk.
  • The PBX includes P-Asserted-Identity, as recommended for all outbound calls.

NAT

If your PBX is behind NAT, make sure it advertises its public address correctly in SIP and RTP.

Incorrect NAT configuration can cause problems including:

  • no audio;
  • one-way audio;
  • calls disconnecting shortly after being answered;
  • inbound calls failing to reach the PBX.

Your PBX documentation should describe how to configure its external or public address and local network ranges.

For a username and password trunk, your PBX must also keep its registration reachable through NAT. Use your PBX's keep-alive or qualify setting for the trunk, so we can deliver incoming calls to the address it registered from.

SIP ALG

We strongly recommend disabling SIP ALG on your router or firewall.

SIP ALG attempts to modify SIP traffic as it passes through a router or firewall and can cause unpredictable behaviour.

Problems caused by SIP ALG can include:

  • failed calls;
  • incorrect SIP addresses;
  • one-way or missing audio;
  • calls disconnecting unexpectedly;
  • intermittent routing problems.

Troubleshooting

If calls are not working, check the following first:

  1. For an IP address trunk, your PBX's public IP address matches the one on your trunk in Dial 9 Connect.
  2. For a username and password trunk, your PBX is registered using the full username, including the prefix, and the current password.
  3. Your trunk shows as online under Trunking > Trunks in Dial 9 Connect.
  4. Outbound calls are being sent to sip.dial9.co.uk.
  5. Your number's destination is Send to a trunk, and your PBX has an inbound route for the number in E.164 format, for example 441202912444.
  6. Destination numbers are being sent in E.164 format.
  7. Your PBX is sending a P-Asserted-Identity header.
  8. Your firewall allows the required Dial 9 SIP and RTP traffic.
  9. SIP ALG is disabled.
  10. NAT is configured correctly on your PBX.

For additional help, see our Troubleshooting guide or one of our PBX-specific configuration guides: