Skip to main content

Palindrome Checker

Check if text is a palindrome and find palindromic words inside a sentence.

Written by Golam Rabbani, Founder & Lead Engineer

Try "A man a plan a canal Panama" or "racecar".

Comparison rules

How to use this palindrome checker

  1. Type a word, phrase, or sentence into the input.
  2. Pick the comparison rules β€” ignore letter case, spaces, punctuation, and/or diacritics.
  3. Press Check. The result panel tells you yes/no and shows the normalized form alongside its reverse.
  4. Click "Check each word" to scan every word individually and highlight palindromic ones.
  5. Press Copy result to copy a one-line verdict, or Reset to clear everything.

About this palindrome checker

The palindrome checker normalizes your input according to the toggled rules (optionally lowercase, strip spaces, strip punctuation, strip diacritics), then compares the normalized string to its grapheme-aware reverse. Reversal uses `Array.from()` so multi-byte characters and emoji are flipped as single units rather than as surrogate pairs. If the strings match, the input is a palindrome. If not, the tool reports the first position where the forward and reversed strings diverge so you can see exactly where the mismatch is.

A concrete example. Input: `"A man, a plan, a canal: Panama"` with default settings (ignore case, spaces, and punctuation).

The text normalizes to `amanaplanacanalpanama` (21 letters). Reversed: `amanaplanacanalpanama`. They match β€” the verdict is "It IS a palindrome." Switch off "Ignore punctuation" and the normalized form becomes `aman,aplan,acanal:panama`, which no longer matches its reverse, so the verdict flips to "Not a palindrome" with a first-mismatch position of 5.

The per-word scan tokenizes the input on whitespace and runs the same check on each word, surfacing palindromes like `level`, `racecar`, `noon`, and `madam`. Useful for puzzle solving, recreational linguistics, and checking string-handling edge cases in code. Everything runs locally in your browser.

FAQ

What is a palindrome?
A palindrome is a string that reads the same forwards and backwards. Strict character-level palindromes (like `racecar`) match without any normalization; word- and sentence-level palindromes (like `A man, a plan, a canal: Panama`) require ignoring case, spaces, and punctuation.
Why do I need to "ignore" things?
Most natural-language palindromes only work after normalizing β€” punctuation, spaces, and case differences would otherwise break the symmetry. The default toggles match the most common convention; flip them off to do a strict character-by-character check.
How are emoji and accented letters handled?
Reversal iterates over Unicode code points, so 🌍 and "Γ©" reverse as single graphemes. With "Ignore diacritics" enabled, "Γ©" is decomposed to "e" before comparison, so words like `AnnΓ‘` become `anna` β€” a palindrome.
What does the "first mismatch" position mean?
When the forward and reversed normalized strings differ, the tool reports the 1-indexed position of the first character that does not match. This is useful for narrowing down where to edit when you want to turn a near-palindrome into a real one.
Does the per-word scan use the same rules?
Yes. Each word is normalized with the same toggled rules and checked individually. Single-letter words are skipped (they trivially equal their reverse). The matched count is shown so you can quickly see how many words inside the sentence are palindromic.
Is my input uploaded anywhere?
No. Normalization, reversal, and comparison all run locally in your browser. The input is never sent to a server, logged, or stored.