New Zealand phone number format
Country code +64, 9 digits after it. Below is the same example written every way you are likely to need it.
Convert your own New Zealand number
Paste it however you have it, with or without the leading 0 — you get it back in every notation below, plus whether that number is really allocated.
Paste the number however you have it — national digits are fine, the country is already set. Change the picker if the number is from somewhere else.
Example mobile number
This is a numbering-plan example, not a real subscriber’s line. It is generated from the same data the validator uses, so it always matches what the API accepts.
Why your form rejects valid New Zealand numbers
Nearly every wrongly-rejected New Zealand number on a signup form comes down to one of three things.
The leading 0 is being kept, or the country code glued in front of it
A New Zealand user types 021 123 4567. The 0 is a national trunk prefix — it is replaced by +64, not appended to it. Concatenating gives +640211234567, one digit too many, and every validator downstream calls it invalid.
A length check borrowed from another country
New Zealand runs 9 digits after +64. A hand-written \d{10} was almost certainly correct for whichever country the form was built in, and is wrong here. Length rules are per-country and several countries use more than one.
A regex cannot know what was ever issued
Right country code and right length still passes numbers no carrier was ever assigned — which is exactly what someone inventing a number at signup produces. Pattern matching answers “could this exist”, never “does it”.
For the first two, use a numbering-plan library rather than a pattern. This is the same call the examples on this page are generated from:
import { parsePhoneNumberFromString } from "libphonenumber-js"; // what a New Zealand user types into your form const typed = "021 123 4567"; const n = parsePhoneNumberFromString(typed, "NZ"); n?.isValid(); // true n?.format("E.164"); // "+64211234567" <- store THIS
What parsing still cannot tell you
The third one has no offline answer. Whether the range was allocated, whether it is mobile, fixed line or VoIP, and whether the number has been reported for abuse are all lookups, not patterns — and on a signup form they are the half that decides anything.
curl "https://www.layercall.com/v1/lookup/phone?phone=%2B64211234567" \ -H "X-Api-Key: YOUR_KEY"
1,000 lookups a month free, no card. Get an API key.
Got a column of them?
One number is a demo. If what you actually have is a CRM export, a signup dump or a list you inherited, paste the whole thing — every row gets parsed and scored, New Zealand numbers alongside any other country, with duplicates removed and counted first.
Check a whole list — free, no signup →Questions
Why does my signup form say a valid New Zealand number is invalid?
Almost always the 0. A New Zealand user types 021 123 4567, and the 0 is a national trunk prefix that +64 REPLACES rather than follows. Code that concatenates the country code onto what was typed produces one digit too many, and every check after that reports an invalid number. Parse with the country instead of pattern-matching the string, and store +64211234567.
How do I convert a New Zealand number to E.164?
Drop any spaces, brackets and dashes, remove the leading 0, and put +64 in front — 021 123 4567 becomes +64211234567. Do it with a numbering-plan library rather than string surgery: the rules differ per country and several countries have more than one valid length. The converter at the top of this page does exactly this and shows the result.
What is the country code for New Zealand?
New Zealand's country calling code is +64. In E.164 — the format almost every API, SMS gateway and CRM expects — it is written with no spaces, brackets or dashes, like +64211234567.
How many digits is a New Zealand phone number?
9 digits after the +64 country code. Written nationally it may show a leading 0 trunk prefix, which is dropped in international form.
Does the leading 0 get included when dialling New Zealand from abroad?
No. The 0 is a national trunk prefix used only inside New Zealand. Dialling internationally you drop it and use +64 instead — this is the single most common cause of "invalid number" errors in signup forms.
Is a correctly formatted number the same as a real one?
No, and conflating the two is the usual mistake. Formatting only says a number could exist. It does not say whether the range was ever allocated, whether it is mobile, fixed line or VoIP, or whether it is worth trusting on a signup — those need a lookup against numbering-plan data.