Reverse Text

Reverse text by character, by word or by line. Each mode has its own button, so you can flip a whole string, a sentence's word order or a list.

Updated

Text Tools● Free No upload Instant

Loading Reverse Text…

Your browser is preparing the tool. It runs 100% locally.

Quick answer

Paste text and pick a mode: reverse characters turns Hello into olleH, reverse words turns the cat sat into sat cat the, and reverse lines puts the last line first. Character reversal works on code units, so an emoji or accented character made of several units can break when flipped. The flipping happens in your browser and your text is never uploaded.

What the Reverse Text does

The tool flips text in the direction you choose. Character mode mirrors the whole string back to front. Word mode keeps each word intact and flips their order. Line mode flips the order of the lines and leaves each line as it is.

Use it to mirror a string, put words or lines in the opposite order, or make back-to-front text for a puzzle, a novelty message or a test.

How it works

Each mode works on a different unit. Reverse characters splits the text into characters and reverses the sequence. Reverse words splits on the spaces between words, reverses that list and rejoins it with spaces. Reverse lines splits on line breaks and reverses the order of the lines.

The same text therefore gives three different results. Character mode produces a true mirror. Word mode keeps the words readable but reorders them, and line mode turns a list or block upside down.

Processing pipeline

  1. Choose the mode. Pick reverse by character, by word, or by line.
  2. Split into units. Break the text into characters, words, or lines accordingly.
  3. Reverse the order. Flip the sequence of those units.
  4. Rejoin. Put the units back together to give the reversed text.

Three reverse modes

characters : Hello → olleH words : the cat sat → sat cat the lines : flips the order of the lines (last line first)
Worked example
Hello → olleH (characters) · the cat sat → sat cat the (words)

Character reversal works on code units. A character made of several units, such as an emoji, a flag or a combining accent, can break or render oddly when reversed. Word and line modes don't have this problem.

Standards and references

  • Character reversal: Mirrors the string by reversing its characters. It works on code units, the units a string is stored in, which is why some multi-unit characters don't reverse cleanly.
  • Word and line reversal: Reverse words splits on whitespace and flips the word order. Reverse lines flips the order of the lines. Both keep each unit intact and change only the sequence.
  • Code units and emoji: Many emoji, flags and combining marks are stored as more than one code unit. Reversing by character can separate those units, so the result may break or look wrong.

Accuracy and limits

For ordinary text each mode does what its name says: a character mirror, a word-order flip or a line-order flip. Running the same mode again restores the original.

Character reversal can break multi-unit characters. An emoji or a letter with a combining accent is stored as several code units, and reversing the sequence can split or scramble them. Word and line modes keep each unit whole, so they avoid the problem.

Word reversal splits on whitespace, so a run of spaces becomes a single gap in the output. The words stay the same. Only their order and the spacing between them change.

Line reversal depends on line breaks. Text without any is a single line and comes back unchanged in line mode, so use character or word mode for one-line text.

Real-world uses

Mirroring a string

Flip text back to front by character.

Reversing word order

Put the words of a sentence in the opposite order.

Flipping a list

Reverse the order of lines top to bottom.

Puzzles and novelty

Make back-to-front text for a puzzle, a joke or a test.

When it fits, and when it doesn't

Good for

  • Reversing characters, words or lines
  • Mirroring a string
  • Flipping a list of lines
  • Puzzles and novelty text

Not the best choice for

  • Reversing emoji-heavy text by character
  • Sorting (this reverses, not sorts)
  • Right-to-left language display
  • Bidirectional text handling

To put lines in alphabetical order, use a line sorter. Right-to-left scripts and bidirectional text need proper text-direction handling, which a character flip doesn't provide.

Frequently asked questions

What are the three reverse modes?
Reverse characters mirrors the whole string (Hello becomes olleH). Reverse words flips the order of the words and keeps each word intact (the cat sat becomes sat cat the). Reverse lines flips the order of the lines.
Why does my emoji break when I reverse characters?
Many emoji, flags and accented letters are stored as more than one code unit. Reversing by character can split those units and scramble the emoji. Reverse words or lines instead to keep them whole.
Does reversing twice give back the original?
Yes, as long as you use the same mode both times. Reversal undoes itself, so two character flips, two word flips or two line flips return the original text.
How is reverse words different from reverse characters?
Reverse words keeps each word readable and only flips their order, so the cat sat becomes sat cat the. Reverse characters mirrors the entire string, so the words themselves come out backwards too.
What does reverse lines do?
It puts the last line first and the first line last. The text inside each line stays the same, which makes it handy for turning a list upside down.
Does it sort the text?
No, it only reverses the order. A sorted list comes out in reverse sort order, and an unsorted list simply comes out flipped. To sort, use a line-sorting tool.
What happens to spaces when I reverse words?
The tool splits on whitespace and rejoins the words with single spaces, so several spaces between two words become one. The words themselves stay the same.
Can it reverse a single line of text by line?
Reverse lines needs more than one line to have an effect. A single line comes back unchanged in line mode, so use character or word mode for one-line text.
Is reverse text useful for anything practical?
Reversing word or line order helps rearrange a list or sentence. Character reversal is sometimes used as simple obfuscation, but it gives no real security.
Does it handle right-to-left languages?
It reverses character order mechanically, which is different from right-to-left display. Arabic, Hebrew and other right-to-left scripts need text-direction handling, not a character flip.
Is my text uploaded?
No. Your browser does the reversal and sends nothing to a server, so the text stays on your device.
Why use word reverse instead of just retyping?
Flipping a long sentence or list by hand is slow and easy to get wrong. The tool reorders it instantly and exactly.

References

There is one button per mode: characters, words or lines. Character mode works on code units, so it can split an emoji or an accented letter into pieces.

PopularHot

Word Counter

Count words, characters, sentences and paragraphs as you type, with reading and speaking time alongside.

TextOpen Tool
Trending

Text Diff Checker

Paste two versions of a text and see what changed line by line, with additions in green and removals in red.

TextOpen Tool

Find and Replace Text

Find and replace every match in your text at once, with optional case-insensitive and regex modes. Plain searches match literally.

TextOpen Tool
Popular

Case Converter

Switch text between UPPERCASE, lowercase, Title Case, Sentence case, and aLtErNaTiNg with one click per case.

TextOpen Tool
Trending

Lorem Ipsum Generator

Generate placeholder Lorem Ipsum paragraphs, starting with the classic opening line or fully random.

TextOpen Tool

Remove Duplicate Lines

Remove duplicate lines from a list while keeping the first copy of each in its original position.

TextOpen Tool

Back to the Reverse Text

Your file is processed on this device and never uploaded, and there's no account to create.