Home › Developer Tools › Phone Number Formatter

Phone Number Formatter

Paste a list of phone numbers or open a CSV and get every number in one consistent format: E.164 for CRMs and SMS tools, international, national or tel: links. Each number is validated against Google's libphonenumber rules for its country, with invalid and duplicate numbers flagged.

Last updated:

Loading phone number metadata…

Advertisement
Advertisement

How to use the Phone Number Formatter

  1. Paste your phone numbers, one per line, or open a CSV file that has a phone column.
  2. Choose the default country used for numbers written without a country code, such as United States (+1).
  3. Pick the output format: E.164 for databases and SMS tools, international for display, national for local use, or tel: links for websites.
  4. Decide what happens to invalid numbers: keep the original text, leave the cell empty or write INVALID.
  5. Copy or download the formatted list, or for CSV input download the file with the formatted column added.

One number in every output format

FormatUS exampleUK exampleUse it for
E.164+12015550123+441212345678Databases, CRMs, SMS and messaging APIs
International+1 201 555 0123+44 121 234 5678Websites, email signatures, business cards for a global audience
National(201) 555-01230121 234 5678Lists used only inside one country
tel: link (RFC 3966)tel:+1-201-555-0123tel:+44-121-234-5678<a href> click-to-call links on web pages
Digits only12015550123441212345678Systems that reject the plus sign; WhatsApp wa.me links

How local numbers are converted

  1. Remove formatting: spaces, dots, dashes, brackets and the "(0)" sometimes written in international numbers are dropped.
  2. Find the country: a leading +, 00 or 011 means the next digits are the country code (1 to 3 digits). Otherwise the default country is used.
  3. Drop the trunk prefix: the national dialing prefix (0 in the UK, Germany, France, India, Australia; 1 in the US and Canada) is not part of the international number, so 07400 123456 becomes 7400 123456. Italy is an exception: its leading 0 is kept.
  4. Validate the remaining national number against the country's length and number-range rules, and detect its type.

Tips for clean contact lists

  • Store E.164, display national. Save numbers in E.164 so every system can read them, and format them for people only when showing them.
  • Numbers buried in text? Pull them out of emails, PDFs or notes first with Extract Phone Numbers, then format them here.
  • Tidy the rest of the file (stray spaces, empty rows, duplicate records) with the CSV Cleaner, and look up dialing codes in the Country Codes List.

Frequently asked questions

What is the E.164 phone number format?

E.164 is the international numbering standard of the ITU. An E.164 number starts with a plus sign followed by the country code and the national number, with no spaces, dashes, brackets or trunk zero, and has at most 15 digits. For example, the US number (201) 555-0123 becomes +12015550123 and the UK number 0121 234 5678 becomes +441212345678. Most CRMs, SMS gateways and messaging APIs expect this format.

How does the formatter know the country of a local number?

Numbers that start with + or an international prefix (00, or 011 from the US and Canada) carry their own country code. Numbers without one are read as local numbers of the default country you choose, so 07400 123456 with United Kingdom selected becomes +447400123456. Pick the country your list mostly comes from.

What is the difference between valid and possible?

A possible number has a plausible length for its country. A valid number also matches the ranges that are actually assigned by that country's numbering plan, for example a real area code or mobile prefix. Possible-but-not-valid numbers are shown in amber; tick Treat possible numbers as invalid to reject them.

Does valid mean the phone number is in service?

No. Validation checks the number against each country's numbering plan, so it tells you the number could exist and what type it is. It cannot tell whether a specific line is connected or who owns it; that requires a paid carrier lookup.

Can I format a phone column in a CSV file?

Yes. Open the CSV (or paste it with its header row). The phone column is detected from its name, such as Phone or Mobile, and you can change it. Download CSV then returns your original file with a formatted column and a status column added next to it, or with the original column replaced.

Which library is used for validation?

The tool uses libphonenumber-js, a JavaScript port of Google's libphonenumber with its full metadata, loaded into your browser. If that file cannot be downloaded (for example because of a content blocker), a basic mode checks country codes and lengths for 60 common countries instead, and the status line says so.

Are my phone numbers uploaded?

No. Parsing and formatting happen entirely in your browser; the numbers are never sent to a server.

Are all the tools on FreeToolCabin tested for quality and accuracy?

Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.

Related tools

Extract Phone NumbersFind phone numbers in any text, normalize them to E.164, remove duplicates and export CSV.CSV CleanerClean messy CSV in one click: trim spaces, drop empty rows and columns, fix headers, dedupe.Country Codes ListSearch ISO 3166 alpha-2, alpha-3 and numeric country codes with calling codes and TLDs.WhatsApp Link GeneratorCreate wa.me click-to-chat links with a pre-filled message, button HTML and a QR code.Area Code Time Zone LookupEnter a US or Canadian area code to see its state, time zone and current local time.JSON FormatterBeautify, minify and validate JSON, with a collapsible tree view.SQL Formatter & BeautifierFormat, beautify or minify SQL queries for MySQL, PostgreSQL and more.JavaScript BeautifierFormat and beautify messy or minified JavaScript, or minify it.HTML FormatterBeautify and indent HTML code with a live preview.CSS FormatterBeautify CSS with indent controls and optional property sorting.XML FormatterBeautify, validate and minify XML with a collapsible tree view.ZIP File CreatorCompress files and folders into a ZIP.YAML Validator & FormatterValidate, format and minify YAML, and convert YAML to JSON or back.HTML MinifierMinify HTML: strip comments and whitespace safely and see how many bytes you save.CSS MinifierMinify CSS with csso or a built-in engine and see the size saved instantly.JavaScript MinifierMinify JavaScript with Terser: compress, mangle and see how many bytes you save.JSON MinifierMinify and validate JSON, sort keys and see exactly how many bytes you save.Code Diff CheckerCompare two code files side by side or unified, with syntax colors and changes highlighted.IPv6 Expander & CompressorExpand IPv6 addresses to full form or compress them per RFC 5952, one or many at once.GraphQL FormatterPretty-print and indent GraphQL queries, mutations and schemas, or minify them, instantly.CSS ValidatorValidate CSS: syntax errors, unknown properties and invalid values by line, plus auto-fix.Gzip Compress / DecompressGzip or deflate text and files, get Base64 output, and decompress Base64 or .gz files.IBAN ValidatorCheck an IBAN's mod-97 checksum, country and length, and see its bank code and account parts.JavaScript Syntax CheckerCheck JavaScript for syntax errors with line and column, for any ES version, script or module.JSON Schema ValidatorValidate JSON against a JSON Schema (draft-07, 2019-09, 2020-12) with clickable error paths.Markdown FormatterBeautify Markdown with Prettier: list markers, prose wrap, aligned tables and live preview.PHP FormatterBeautify PHP code with Prettier PHP: PSR-12 style, indent and brace options, syntax errors.TypeScript FormatterFormat TypeScript and TSX code with Prettier: width, tabs, semicolons and quotes options.XML MinifierMinify and validate XML: strip whitespace and comments, keep CDATA, see the size savings.C# FormatterBeautify C# code online: Allman or K&R braces, indent size and line width, clang-format option.HTML ValidatorCheck HTML for errors and warnings with line numbers, locally or with the W3C Nu checker.Java FormatterBeautify Java code online: indent size, brace style and line width, with clang-format option.JavaScript ObfuscatorObfuscate JavaScript with string encoding, renaming and control-flow flattening presets.Python FormatterFormat Python code in Black/Ruff style: line length, quote style, indent, copy or download.Responsive Design CheckerPreview any website at phone, tablet, laptop and desktop sizes side by side, with rotate and zoom.Browser Compatibility CheckerSearch CSS, JavaScript and HTML features and see which browser versions support them.Core Web Vitals CheckerCheck real-user LCP, INP and CLS for any URL or site and see if it passes Core Web Vitals.Heading Structure CheckerPaste HTML to see its H1-H6 outline and catch missing H1s, multiple H1s and skipped levels.Strftime Format BuilderBuild Python and C strftime format strings by clicking tokens, with a live preview and reference.Website Hosting CheckerFind out who hosts a website: hosting provider, IP addresses, ASN, network owner and location.Routing Number ValidatorCheck a US ABA routing number's checksum and format and see its Federal Reserve district.Spam Word CheckerScan an email subject and body for spam trigger words, excess caps, exclamation marks and risky links.Check Digit CalculatorCalculate or validate check digits for UPC, EAN, GTIN, SSCC, ISBN, ISSN and mod 11 codes.Luhn Algorithm CheckerValidate numbers with the Luhn mod 10 check or calculate the missing check digit, step by step.XSD ValidatorValidate XML against an XSD schema in your browser and see each error with its line number.
See all 41 Code Formatters & Validators →