Locale Converter & Analyzer for US Devs

Convert, parse, and compare locale strings. See real-time preview of number, currency, and date formats for American English and global locales.

Popular Locales

Try Common Inputs

Browser Support

Enter a locale identifier to see parsing results and formatting previews...

How to Use

  1. 1

    Paste Any Locale String

    Start with browser locales, POSIX values like en_US.UTF-8, script tags like zh_Hans_CN, or an Accept-Language header.

  2. 2

    Normalize The Tag

    The tool canonicalizes the value into a BCP 47 locale and shows matching POSIX, HTML lang, and Intl snippets.

  3. 3

    Copy The Right Format

    Use the output block that fits your use case: web markup, JavaScript Intl, environment variables, or QA docs.

  4. 4

    Compare Output Differences

    Switch to compare mode to inspect how two locales differ for numbers, currency, dates, and collation behavior.

Why Use Be Converter?

Browser Native

Powered by built-in Intl APIs. No server calls, no external dependencies. Works offline and respects your privacy.

Real-time Preview

Instantly see how numbers, dates, currencies, and lists are formatted in any locale as you type.

Normalize Real Inputs

Paste POSIX locales, ICU-style underscores, or Accept-Language headers and turn them into clean BCP 47 and HTML-ready locale strings.

Comprehensive Analysis

Parse locale components, show display names in multiple languages, and compare two locales side by side.

Perfect For

Convert en_US.UTF-8 to en-US Prepare HTML lang attributes Normalize Accept-Language headers QA locale fallback chains Check Intl resolved locales Document i18n implementation details

Frequently Asked Questions

What is a locale identifier?
A locale identifier is a short code that identifies a specific combination of language, region, and script. For US developers, you'll often see tags like 'en-US' (English as used in the United States) or 'es-419' (Latin American Spanish). These codes tell browsers and servers how to display items like currency (USD vs EUR) and dates (MM/DD/YYYY vs DD/MM/YYYY).
What is the difference between BCP 47 and POSIX locale formats?
BCP 47 uses hyphens to separate components (e.g., en-US) and is the standard for modern web technologies like HTML and JavaScript. POSIX uses underscores (e.g., en_US) and is common in legacy Unix/Linux systems. If you are configuring a server in New York, you might see POSIX, but for web development, you will convert everything to BCP 47.
How does this tool work without a server?
This tool uses the browser's built-in Intl API family to parse locale identifiers and generate formatting previews. All processing happens locally in your browser—no data is sent to any server. This ensures fast performance and privacy.
Why do some locales show different results across browsers?
The Intl API implementation and locale data vary between browsers and operating systems. Chrome on Windows might format a date slightly differently than Safari on macOS due to different underlying data versions. The resolved locale shown in the results reflects exactly what your specific browser environment supports.
What does "resolved locale" mean?
When you request a generic locale like "en", the browser often resolves it to a more specific default locale, such as "en-US" for a user in Chicago. The resolved locale is the specific tag the browser actually uses for formatting numbers, dates, and currencies, which may differ from your generic input.

Common Locale Conversion Examples

These are the most common locale-string cleanup tasks developers and localization teams search for when they need a locale converter online.

Input
en_US.UTF-8
Output
en-US

Convert Unix-style locale environment values into a BCP 47 tag you can use in frontend code.

Input
zh_Hans_CN
Output
zh-Hans-CN

Normalize script subtags with the casing web platforms expect.

Input
sr_RS@latin
Output
sr-Latn-RS

Translate a POSIX modifier into a script-aware locale tag for product localization.

Input
Accept-Language: fr-CA,fr;q=0.9
Output
fr-CA

Extract the preferred locale from a browser header before routing or formatting content.

Understanding Locale Identifiers

BCP 47 Structure

A BCP 47 language tag consists of subtags separated by hyphens: language (required), script (optional), region (optional), and variants. For a US user, 'en-Latn-US' represents English, Latin script, in the United States.

  • Language only en, es, fr
  • Language + Region en-US, en-CA, es-MX
  • Language + Script zh-Hans, sr-Latn
  • Full tag en-Latn-US, zh-Hans-CN

Intl API in Practice

The JavaScript Intl API provides locale-aware formatting for numbers, dates, and lists. Use Intl.Locale to parse identifiers, Intl.DisplayNames to get names, and Intl.NumberFormat/DateTimeFormat for presentation.

  • Intl.getCanonicalLocales(["pt-br"]) - canonicalize
  • new Intl.Locale("zh-Hans-CN") — parse
  • Intl.DisplayNames — display names
  • Intl.NumberFormat — numbers
  • Intl.DateTimeFormat — dates

Best Practice: Always use the most specific locale tag available. For US applications, ensure you explicitly support 'en-US' rather than relying on generic 'en' to guarantee the correct date and currency formats appear for American users.

Copied to clipboard!