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

Hey there! I'm a developer, designer, and digital nomad building cool things with Remix, and I'm also writing Moulton, the Remix Community Newsletter

About once per month, I send an email with:

  • New guides and tutorials
  • Upcoming talks, meetups, and events
  • Cool new libraries and packages
  • What's new in the latest versions of Remix

Stay up to date with everything in the Remix community by entering your email below.

Unsubscribe at any time.