Skip to content

Dial Pattern Examples

An outbound route decides which trunk (the connection between your phone system and your phone-service carrier) carries a call, based on the digits an extension dials. The Pattern field is what does the matching, and the Strip and Prepend fields let you reshape the number before it reaches the carrier. The examples below build a pattern for each common call type so you can see how the pieces fit together, then adapt them to your own numbering plan.

A dial pattern is a template made of literal digits and wildcards. The three building blocks used in these examples are:

  • X, any single digit, 0 through 9.
  • Z, any single digit, 1 through 9 (in other words, any digit except 0).
  • ., the remaining digits, matching one or more of whatever follows.

Count the characters in a pattern and you know how many digits a caller must dial for it to match. The examples that follow are based on the numbering plan for Xiamen, China; substitute the digit lengths and prefixes your region uses.

In Xiamen, local numbers are seven digits long and never begin with 0 (for example, 5503305). To match a seven-digit number whose first digit is 1 through 9, use one Z for the leading digit followed by six X wildcards.

PatternStripPrepend
ZXXXXXXLeave blankLeave blank

A long-distance call in this plan is a four-digit area code plus a seven-digit local number, such as 0595-7588123.

  • The area code has the form 0ZXX: it starts with 0, and its second digit is never 0.
  • The local number is the same seven digits as before, and it does not start with 0.

Chaining the two together gives an eleven-character pattern.

PatternStripPrepend
0ZXXZXXXXXXLeave blankLeave blank

Every mobile number in China is eleven digits and begins with 1 (for example, 15880260666). Match the leading 1 as a literal, then allow any digits for the remaining ten positions.

PatternStripPrepend
1XXXXXXXXXXLeave blankLeave blank

International numbers all start with 00, and their total length varies by destination. Match the 00 prefix as literals, then use the . wildcard to accept whatever digits follow.

PatternStripPrepend
00.Leave blankLeave blank