Remove accents & diacritics
What is a Remove Accents Diacritics?
Accented characters such as é, ñ, ü and ç are essential in many languages, but some systems cannot handle them: legacy databases, ASCII-only file names, URL slugs, payment card name fields and simple search indexes. This tool removes diacritics while keeping the base letters, turning Crème brûlée à São Paulo into Creme brulee a Sao Paulo.
How to use it
- Paste the text.
- Choose the normalization option if offered.
- Copy the cleaned text.
How it works
Unicode can represent é either as one precomposed character (U+00E9) or as e followed by a combining acute accent (U+0065 U+0301). Normalizing to NFD splits characters into base letters and combining marks. Removing all combining marks (Unicode range U+0300 to U+036F) leaves the plain letters. In JavaScript:
text.normalize('NFD').replace(/[\u0300-\u036f]/g, '')Characters that need special handling
Some letters are not built from a base letter and an accent, so normalization alone leaves them unchanged:
- German ß should become ss.
- Scandinavian ø and æ become o and ae.
- Polish ł becomes l.
- Turkish dotless ı is already a separate letter.
Use cases
- Creating URL slugs and file names.
- Accent-insensitive search, so resume finds résumé.
- Matching names across systems with different encodings.
When not to strip accents
Removing diacritics can change meaning: Spanish año (year) and ano (anus), or French pêcher (to fish) and pécher (to sin). Keep the original text for display and use the stripped version only for matching or technical identifiers.
Frequently Asked Questions
How do I remove accents in JavaScript?
Normalize the string to NFD and remove characters in the range U+0300 to U+036F with a regular expression.
Why is ß or ø not converted?
They are separate letters rather than letters with combining accents, so they need explicit replacement such as ss and o.
What is Unicode normalization?
Converting text to a standard form, such as NFC, which combines characters, or NFD, which separates base letters and accents.
Should I store names without accents?
No. Store the original spelling and use the accent-free version only for search, matching or identifiers.