Regex for International Phone Number

Universal regular expression for international phone validation compliant with ITU E.164 standard: optional leading plus and 2 to 15 digits.

/

⚡ Live Interactive Sandbox

Validation Result: MATCH ✓

Pattern Breakdown & Tokens

  • • ^\+? — optional leading plus symbol for international dialing
  • • [1-9] — country dialing code starting with non-zero digit
  • • \d{1,14}$ — 1 to 14 subscriber digits per E.164 specifications

Code Snippets

JavaScript
const phoneRegex = /^\+?[1-9]\d{1,14}$/;
const isValid = phoneRegex.test(phone);
Python
import re
pattern = r"^\+?[1-9]\d{1,14}$"
is_valid = bool(re.match(pattern, phone))
Go (Golang)
matched, err := regexp.MatchString(`^\+?[1-9]\d{1,14}$`, phone)
PHP
$isValid = preg_match('/^\+?[1-9]\d{1,14}$/', $phone);

Open the full tool: Open Full Regex Tester →

FAQ

How does this regular expression for International Phone Number work?

Universal regular expression for international phone validation compliant with ITU E.164 standard: optional leading plus and 2 to 15 digits. The pattern is: ^\+?[1-9]\d{1,14}$

How to use this regex in JavaScript and Python?

In JavaScript: new RegExp("^\+?[1-9]\d{1,14}$").test(input). In Python: re.match(r"^\+?[1-9]\d{1,14}$", input).

Can I test complex regular expressions online?

Yes, use our full in-browser Regex Tester tool with live syntax highlighting, group capture table, and zero server uploads.

🔗 Share this page

TelegramWhatsAppX