If you have ever configured a SIP trunk and your outbound calls failed with a 404 error, or your inbound DID routing stopped working after a migration, or your dialer sent calls to the wrong destination — there is a good chance the problem was E.164 formatting. E.164 is the international standard for phone number formatting, and SIP trunking infrastructure depends on it. Get the format wrong and calls do not route. Get it right and you never think about it again.
This is a short, practical guide written by SIPNEX, an FCC-licensed carrier. We see E.164 formatting errors on support tickets every week — almost always from operators migrating from PRI (where number formatting was handled by the carrier’s switch) to SIP (where your system must present numbers in the format the carrier expects). Understanding E.164 prevents those tickets.
What E.164 is
E.164 is a numbering plan defined by the International Telecommunication Union (ITU) in recommendation E.164. It specifies the format for telephone numbers used on the global public switched telephone network. The standard defines a maximum length of 15 digits and a structure that starts with a country code followed by the subscriber number.
For North American numbers (US, Canada, and several Caribbean nations under the NANP — North American Numbering Plan), the E.164 format is:
+1XXXXXXXXXX
That is a plus sign, the country code 1, and ten digits (3-digit area code + 7-digit subscriber number). No spaces, no dashes, no parentheses, no dots. Just +1 followed by ten digits.
Examples:
- Dallas number: +12145551234
- New York number: +12125559876
- Toll-free number: +18005551000
- Canadian number: +14165557890
For international numbers outside NANP, the format follows the same pattern but with different country codes and varying subscriber number lengths:
- UK mobile: +447911123456 (country code 44)
- German landline: +4930123456 (country code 49)
- Australian number: +61291234567 (country code 61)
The maximum 15 digits includes the country code. The minimum is not defined by the standard but in practice no valid E.164 number is shorter than 7 digits (some small island nations).
Why E.164 matters for SIP trunking
PRI trunks and analog phone lines handled number formatting at the carrier’s switch level. You could dial “5551234” or “2145551234” or “12145551234” and the carrier’s signaling equipment would figure out what you meant based on your local dialing plan. SIP does not work that way.
SIP is an internet protocol. It routes calls based on the exact content of the SIP URI in the Request-URI and the From/To headers. When your PBX sends a SIP INVITE, the called number must be in a format that the carrier’s routing engine can parse unambiguously. Most SIP carriers — including SIPNEX — expect or require E.164 format for both outbound dialing and caller ID presentation.
Outbound calls. When your dialer places a call to +12145551234, the carrier receives a SIP INVITE with that exact string in the Request-URI. The carrier’s routing engine strips the +1, identifies the area code (214), looks up the rate center and terminating carrier for the NPA-NXX (214-555), and routes the call. If your system sends “2145551234” without the +1 prefix, some carriers will normalize it automatically. Others will return a 404 (Not Found) or 484 (Address Incomplete) error because the number does not match the expected format.
Caller ID. The From header of your SIP INVITE contains your outbound caller ID. For STIR/SHAKEN attestation, the carrier must match this number against your authorized DID list. If your system sends the CID as “2145551234” but your carrier’s STIR/SHAKEN database stores it as “+12145551234,” the match fails and the carrier signs at B-level instead of A-level because it cannot confirm number authority. A formatting mismatch in the caller ID field can silently downgrade your attestation level on every call without any visible error.
Inbound routing. When an inbound call arrives for one of your DIDs, the carrier sends a SIP INVITE to your system with the called number in the To header. If your PBX expects the number in one format (e.g., “2145551234”) but the carrier sends it in E.164 (“+12145551234”), your inbound routing rules may not match and the call goes to a default destination or gets rejected. This is one of the most common issues after migrating from PRI to SIP — the PBX was configured to match 10-digit numbers, and the new SIP carrier delivers 11-digit E.164 numbers.
Common E.164 formatting mistakes
These are the errors we see most frequently on SIPNEX support tickets.
Missing the country code. Sending “2145551234” instead of “+12145551234”. Some carriers accept 10-digit numbers and prepend +1 automatically. Others reject the call. Do not rely on carrier normalization — always send E.164 from your system.
Including formatting characters. Sending “(214) 555-1234” or “214.555.1234” or “214-555-1234”. SIP URIs should contain only the plus sign and digits. Parentheses, spaces, dashes, and dots are display formatting for human readability — they do not belong in SIP signaling. Most SIP stacks strip these automatically, but some edge cases can cause routing failures.
Leading zeros. Some international dialing conventions use a leading zero for domestic calls (e.g., dialing 0214 in certain countries). E.164 never includes a leading zero after the country code. For North American numbers, this is rarely an issue, but for international termination it causes routing failures — +440207946 is wrong, +44207946 is correct (the 0 is a domestic dialing prefix, not part of the E.164 number).
Toll-free number formatting. Toll-free numbers follow the same E.164 format: +18005551234, +18885551234, etc. Some systems store toll-free numbers differently from local numbers. They should not — E.164 is E.164 regardless of the number type.
CID mismatch between PBX and carrier. Your PBX sends CID as “2145551234” in the From header. Your carrier’s STIR/SHAKEN database stores your DID as “+12145551234”. The match fails silently. Your calls go out with B-level attestation instead of A-level. Your answer rates drop and you do not know why. This is the most insidious E.164 error because there is no error message — the call completes normally, just with degraded attestation.
How to configure E.164 in common platforms
VICIdial / Asterisk. In your trunk configuration (sip.conf or pjsip.conf), set your outbound dial patterns to prepend +1 to all 10-digit numbers. In the dialplan (extensions.conf), use pattern matching to normalize outbound numbers: exten => _1NXXNXXXXXX,1,Dial(SIP/+${EXTEN}@sipnex) or use the prefix setting in your trunk peer configuration. For caller ID, set the callerid in your campaign settings to E.164 format: +12145551234 rather than 2145551234.
FreePBX. In the Outbound Route configuration, set the dial pattern to match 10-digit numbers and prepend +1. In Trunk settings, ensure the Outbound Caller ID is in E.164 format with the +1 prefix.
Generic SIP devices. In any SIP endpoint or PBX, check the outbound number formatting settings. Look for options labeled “prefix,” “prepend,” or “number manipulation rules” and configure them to add +1 to outbound numbers. Check the caller ID or From header configuration and ensure it includes the +1 prefix.
Testing. After configuring E.164, place test calls and verify in your SIP logs that the INVITE contains the expected format in both the Request-URI (called number) and From header (caller ID). Check with your carrier that your calls are receiving A-level attestation — a formatting error in the CID field can silently cause B-level signing.
E.164 and number portability
When you port numbers between carriers, E.164 format ensures consistency. A ported number retains its E.164 identity regardless of which carrier serves it. The number +12145551234 is always +12145551234, whether it is served by AT&T, Verizon, SIPNEX, or any other carrier. The NPAC (Number Portability Administration Center) routes calls to ported numbers based on the E.164 number — the routing updates when you port, but the number itself does not change format.
During a port to SIPNEX, ensure your PBX configuration uses the same E.164 format for the ported numbers as for newly provisioned SIPNEX DIDs. A common mistake is configuring new SIPNEX DIDs in E.164 (+1XXXXXXXXXX) but leaving ported numbers in the old 10-digit format because that is how the previous carrier delivered them. Normalize everything to E.164 and your routing will be consistent.
Frequently asked questions
What is E.164 format?
E.164 is the international telephone number format defined by the ITU (International Telecommunication Union). It specifies that phone numbers should be written as a plus sign followed by the country code and subscriber number, with no spaces, dashes, or other formatting characters. Maximum length is 15 digits. For North American numbers (US, Canada), the format is +1 followed by 10 digits: +12145551234. E.164 is the standard format used by SIP trunking infrastructure, carrier routing systems, and STIR/SHAKEN attestation databases.
Why does my SIP trunk require E.164 format?
SIP routes calls based on the exact content of the number in the SIP message headers. Unlike PRI or analog systems, SIP does not interpret local dialing plans or automatically add country codes. The carrier’s routing engine expects an unambiguous, globally unique phone number — which is what E.164 provides. Additionally, STIR/SHAKEN attestation requires the carrier to match your outbound caller ID against its database of authorized numbers. If your system sends the number in a format that does not match the database entry (e.g., 10 digits when the database stores 11 digits with +1), the match fails and your attestation is downgraded. Using E.164 consistently ensures correct routing and proper attestation on every call.
Do I need E.164 for domestic US calls?
Yes, for SIP trunking. While some carriers accept 10-digit numbers and normalize them to E.164 internally, relying on this behavior is a risk — different carriers handle normalization differently, and a carrier migration can break your call routing if the new carrier expects strict E.164. Additionally, STIR/SHAKEN attestation matching is format-sensitive. The safest practice is to configure your PBX or dialer to always send numbers in E.164 format (+1XXXXXXXXXX) for both the called number and the caller ID, regardless of whether the call is domestic. This eliminates an entire category of potential routing and attestation problems.
How do I convert my phone numbers to E.164?
For North American numbers, the conversion is simple: add +1 to the front of the 10-digit number and remove all formatting characters. (214) 555-1234 becomes +12145551234. 214-555-1234 becomes +12145551234. 1-214-555-1234 becomes +12145551234 (remove the dash, keep the 1, add the plus sign). For international numbers, replace the domestic dialing prefix (usually 0) with the plus sign and country code. In your PBX, configure outbound dial patterns to perform this conversion automatically so agents and lead lists do not need to change.
SIPNEX SIP trunks accept E.164 format on all outbound calls and deliver inbound calls in E.164 format. Our STIR/SHAKEN attestation database is keyed on E.164 — use the right format and every call gets the A-level attestation it deserves. Get started or see our rates.
Keep Reading
SIPNEX
FCC-licensed carrier with its own STIR/SHAKEN SP certificate. Operator-owned. SIP trunks built for operators who dial at volume.