Jacob Paris
← Back to all content

Guidelines for validating phone numbers

Phone numbers have a maximum length of 15 set by the International Telecommunication Union

The shortest phone number appears to be 8, including the country code, for numbers coming from the Solomon Islands.

Since users may leave out the country code, that makes the largest reasonable minimum as 5 characters.

Phone number extensions are largely unregulated, with the US using a maximum of 4 digits. It's common for the user to label the extension as EXT: 4725, which introduces the requirement for letters in the input as well as additional length

There are a variety of formatting symbols used internationally, most prominently +, (), ., and - as well as whitespace.

Google has a service called libphonenumber which can validate specific numbers to ensure they comply to their specific regional code.

  • Minimum length of 5 characters (Optional)
  • Maximum length of at least 40 (Optional)
  • No character set restriction

Valid phone numbers

  • +1 (780) 445 2524 EXT: 2245
  • +44 113 496 0000
  • 12341
Professional headshot

Hi, I'm Jacob

Hey there! I'm a developer, designer, and digital nomad with a background in lean manufacturing.

About once per month, I send an email with new guides, new blog posts, and sneak peeks of what's coming next.

Everyone who subscribes gets access to the source code for this website and every example project for all my tutorials.

Stay up to date with everything I'm working on by entering your email below.

Unsubscribe at any time.