Fog Creek Software
Discussion Board




What are North America Phone Number Rules?

Does anyone know the rules which govern phone numbers inside North America? Specifically, are areacodes allowed to start with 0, like (011) 727-9341. Or are prefixes allowed to start with 0, ala (707) 021-2323? Are #s all the same digit valid, ala (707) 111-1111.

If anyone knows these rules please let me know. Thanks!

Jeff

Jeff
Tuesday, January 13, 2004

I don't know, but an area code of 011 would be particularly bad since it means international call.

Try http://www.nanpa.com/

pdq
Tuesday, January 13, 2004

From the NANPA site (mentioned in the previous reply):

"NANP (North American Numbering Plan) numbers are ten digits in length, and they are in the format:

NXX-NXX-XXXX

Where N is any digit 2-9 and X is any digit 0-9. The first three digits are called the numbering plan area (NPA) code, often called simply the area code. The second three digits are called the central office code or prefix. The final four digits are called the line number.

The North American Numbering Plan (NANP) was invented in 1947 by AT&T and Bell Laboratories. It conforms to the International Telecommunications Union Recommendation E.164, the international standard for numbering plans.

The NANP is the numbering plan for the Public Switched Telephone Network in the United States and its territories, Canada, Bermuda, and many Caribbean nations, including Anguilla, Antigua & Barbuda, Bahamas, Barbados, British Virgin Islands, Cayman Islands, Dominica, Dominican Republic, Grenada, Jamaica, Montserrat, St. Kitts and Nevis, St. Lucia, St. Vincent and the Grenadines, Trinidad and Tobago, and Turks & Caicos."

==========
The full plan includes some special numbers or restrictions, such as 800-type toll-free area codes, 555 prefix, 411, 911, etc.

Note that these rules have changed over time and will continue to change. Originally, the second digit of the area code was restricted to 0 or 1, and (I think) the second digit of the central office code was restricted to the digits 2-9 (to allow the central office switch to determine if you were making a local or long-distance call by the second digit) - both of these rules were removed as more telephone numbers were required. There are also proposals to increase the number of digits from ten to eleven, either by going to 4-digit area codes or 4-digit central office numbers (creating 8-digit local numbers), or a mixture of both. [I think 8-digit local numbers are long overdue and would be much better than continuing to split existing area code regions, or interlacing area codes as they have done in some states.]

Philip Dickerson
Tuesday, January 13, 2004

As another posted pointed out, the NANPA site has a lot of information about this kind of thing.

In general, an area code takes the format [2-9][0-9][0-9], so neither a 0 or 1 may be used as the initial digit. However, there are some additional restrictions; numbers in the form [2-9]11 are not area codes and are instead reserved for special services (411 information, 911 emergency, and so on). Area codes with 9 in the middle digit are reserved for use when the phone number format expands beyond 10 digits (Y2K redux?). Etc.

There are some restrictions on 7-digit numbers as well. Like area codes, the exchange (initial three digits) uses the format [2-9][0-9][0-9]. Some, such as 555, have special meanings or are otherwise restricted. I don't think there's a fundamental reason why you couldn't have all the same digits in the number; in fact, doing a quick reverse phone number lookup, I can see that there's a business in NYC that has the number 444-4444, for example.

John C.
Tuesday, January 13, 2004

Jeff, in what context do you want to know the phone number "rules"? Are you trying to normalize a database of phone numbers, do you need to know dialing sequences, or something else?

If it's for normalization: area codes and prefixes may not matter. Formatting should be preserved, because it is significant to the user. But in terms of data processing, you may not actually need to know what phone number format is in use. You probably want to identify the country code and add/remove the national or international dialing prefix, but you can avoid having to know each country's phone number rules.

If it's for dialing sequences: good luck. There's simply no way to deterministically dial a phone number (correctly) in the US. You need a lot of information, such as whether a particular call is long-distance or not (area codes cannot help you here); whether 7-, 10- or 11- digit dialing is in effect; whether 8-digit dialing is used for long-distance calls within an area code, etc. These rules vary by location, phone company, and even by phone number within a given area.

Note: Determining dialing sequences isn't a problem for humans. We usually try one way, and then try another way if it doesn't work. But it might be a serious problem for a computer.

In theory most European numbers should be deterministically dialable, but I haven't spent enough time there to know. E.g. -- in the UK can you dial 0 + areacodephonenumber from any location to any other location, or are there areas that require just the phone number segment?

Nate Silva
Tuesday, January 13, 2004

On "phone number rules" here is a good one straight from someone I know who does telecommunications networks for a living:

It is impossible to ascertain whether a particular phone number in a large metropolitan area requires a "1" to precede the area code or not. You basically need to do a real time lookup of the number's area code and exchange and you need to know the rules that apply for the area code and exchange from which you are dialing.

IE: in my area there are regions in area codes outside my own area code that are considered toll-free. The telco (Sprint) basically makes you enter a "1" when you dial *if* the number is chargeable long distance (toll) and requires that you *not* enter the "1" if the number is considered local. This is to say that you cannot simply append 1 to all numbers that require area codes, because the telco will reject the call attempt with a recording if a superfluous 1 is present.

So, you cannot write a phone dialer that can dial a number automatically. The user must enter the 1 prefix (or not) manually.

This is probably due to the architecture of the phone company switches, which vary by telephone company and area served.

FYI.

Bored Bystander
Tuesday, January 13, 2004

"So, you cannot write a phone dialer that can dial a number automatically. The user must enter the 1 prefix (or not) manually.

This is probably due to the architecture of the phone company switches, which vary by telephone company and area served."

This is typically NOT true of mobile phones.  But I suppose there are two reasons for this: (a) The phone is mobile, so it's a pain to change and (b) you are charged for most calls anyway (although not always long distance).

Almost Anonymous
Tuesday, January 13, 2004

Also, mobile phones have a "Send" key that lets you know that you are finished typing.  This helps immeasurably.

Flamebait Sr.
Tuesday, January 13, 2004

Man, I hate it when the phone says "you do not need to dial a 1 before the area code. please hang up and dial again".

pdq
Tuesday, January 13, 2004

sometimes it is true for mobile phones--when you roam. my phone has a built in web browser, and some sites (zagat) let you dial the phone. it presents 3 choices for the number to dial, and all three work when i'm in my home area. i got some really bizare error message using 10-digit dialing in Canada once without the '1'.

note that many of these rules are legally mandated due to different consumer protection rules and court cases in different states. and with area code splits, a different area code might be local (even the same building) but the same area code long distance (older number far away).

mb
Wednesday, January 14, 2004

Sorry for the OT comment, but I've also been wondering what the implications of number portability in the U.S. are for conceptualization of so-called "area codes". Say you have a cell phone in New York and move to L.A., but keep the 917 number. When someone in L.A. calls you on your cell phone, do they have to pay long distance charges even if you're local, or does the system "know" that your phone is now based in L.A. despite its NY-looking area code? I don't personally worry about this since I have unlimited flat-rate long-distance -- just idle curiosity.

John C.
Wednesday, January 14, 2004

John,

I don't think portability extends through area codes like that.

apw
Wednesday, January 14, 2004

exactly--long distance calls are mostly free, so people now sometimes bring their phones and numbers with them when they move.

portability is a different issue; apparently you can't port your number to another carrier if you live out of the area the number 'belongs' to.

mb
Wednesday, January 14, 2004

A propos of nothing, I notice all fictional North American TV characters have numbers prefixed with 555, which apparently signifies an information service in the real world.

Does anybody know the reasons for this convention? Is it to stop bozos from hassling private citizens when they try dial the number and demand to speak to Clark Kent, or something?

Fernanda Stickpot
Thursday, January 15, 2004

Pin pon!

T.J.
Thursday, January 15, 2004

In most countries outside of the Us the cellphone is a national number. Not really portable between carriers and to make it worst often not portable between calling plans either! I suppose the only consolation is that you don't need to buy a finance program to work out which calling plan is best for you.

Stephen Jones
Friday, January 16, 2004

*  Recent Topics

*  Fog Creek Home