Standardize US Phone Numbers Workflow
detail.loadingPreview
This n8n workflow cleans and formats US phone numbers into consistent, standardized formats. It intelligently strips non-numeric characters, adds the US country code '1' if missing, and ensures a unified output for seamless integration with your business applications.
About This Workflow
This n8n workflow offers a robust, automated solution for standardizing US phone numbers, addressing common data inconsistencies. It begins by meticulously stripping all non-numeric characters from the input, ensuring a clean, digit-only string. The workflow then intelligently assesses the phone number's length and country code presence; it automatically prepends the '1' US country code if a 10-digit number is detected or if an 11+ digit number does not already start with '1'. Finally, it outputs the standardized number in several widely used formats, including the international E.164 format (+1##########) and common national formats like (###) ###-#### and 1 (###) ###-####. This automation vastly improves data quality and consistency across your systems.
Key Features
- Automated Data Cleaning: Strips all non-numeric characters (spaces, dashes, parentheses) for a clean, digit-only phone number.
- Intelligent Country Code Handling: Automatically adds the '1' US country code if a 10-digit number is provided or if an 11-digit number lacks it.
- Multi-Format Output: Generates the standardized phone number in E.164 (+1##########), National ((###) ###-####), and Full National (1 (###) ###-####) formats.
- Built-in Validation: Includes checks for number length, allowing you to branch logic for invalid or incomplete entries.
- Sub-workflow Integration: Designed as a modular component, easily callable by other n8n workflows to centralize phone number standardization.
How To Use
- Trigger the Workflow: This workflow is designed to be executed as a sub-workflow. Call it from another n8n workflow and pass the raw
Phone Numberyou wish to format as an input parameter. - Automatic Cleaning: The "Strip phone number formatting" node will automatically remove all non-numeric characters from the input phone number.
- Length and Country Code Check: The workflow proceeds to check the length of the cleaned number and if it starts with the US country code '1'.
- Add Country Code (If Applicable): If the number is 10 digits or an 11+ digit number that does not start with '1' (for US numbers), the "Add valid country code" node will prepend '1' to standardize it.
- Access Formatted Outputs: The final "Format phone numbers" node will output the cleaned and standardized phone number in various formats. In your parent workflow, you can access these outputs using expressions like
{{ $('Format phone numbers').item.json['Phone Number (E-164)'] }}or{{ $('Format phone numbers').item.json['Phone Number (National)'] }}.
Apps Used
Workflow JSON
{
"id": "e0ae14d3-2771-4664-98b3-138c655470a6",
"name": "Standardize US Phone Numbers Workflow",
"nodes": 13,
"category": "Operations",
"status": "active",
"version": "1.0.0"
}Note: This is a sample preview. The full workflow JSON contains node configurations, credentials placeholders, and execution logic.
Get This Workflow
ID: e0ae14d3-2771...
About the Author
SaaS_Connector
Integration Guru
Connecting CRM, Notion, and Slack to automate your life.
Statistics
Related Workflows
Discover more workflows you might like
Instant WooCommerce Order Notifications via Telegram
When a new order is placed on your WooCommerce store, instantly receive detailed notifications directly to your Telegram chat. Stay on top of your e-commerce operations with real-time alerts, including order specifics and a direct link to view the order.
On-Demand Microsoft SQL Query Execution
This workflow allows you to manually trigger and execute any SQL query against your Microsoft SQL Server database. Perfect for ad-hoc data lookups, administrative tasks, or quick tests, giving you direct control over your database operations.
Automate Getty Images Editorial Search & CMS Integration
This n8n workflow automates searching for editorial images on Getty Images, extracts key details and embed codes, and prepares them for seamless integration into your Content Management System (CMS), streamlining your content creation process.