Reverse lines, online
Paste a list, get it back upside-down. Useful for log review, reading commit history newest-on-top, or any time a file landed in the wrong direction.
Or press Ctrl+Enter
When to use this tool
guideSome tools dump logs oldest-first. Flip them so the latest entry is the first thing you read — no chronological detective work.
Got a git log or release notes in oldest-first order? Reverse it in two seconds, paste it back where you need newest-first.
Survey responses, todo lists, ranked picks — sometimes "bottom up" is the right read. Flip and go.
Modeling a queue or stack? Pair reverse with the home-page dedupe to keep the last occurrence of each line instead of the first.
How it works
three steps-
01
Paste your list or upload a .txt
Same threshold as the other tools — 100K lines live, larger files go to download mode automatically.
-
02
Choose your toggles
Trim removes leading/trailing whitespace on every line before flipping. Empty-line removal drops blank rows so the flipped output starts on a real line.
-
03
Hit Run
The last input line becomes the first output line. Order reversal is deterministic — same input always produces the same flipped output.
Under the hood
engine notes- Algorithm
- Native Array.prototype.reverse() in place
- Throughput
- 100K lines reversed in ≈80 ms on a 2024 M3 MacBook Air
- Threading
- Web Worker for files ≥ 2 MB or ≥ 100K lines
O(n) single pass after optional trim/empty filtering. No sort, no comparison — deterministic flip.
Dominant cost is the line-split, not the reversal itself. 80 MB hard cap per run.
Same Worker plumbing as the other tools; the reverse mode is one branch inside the shared engine.
Privacy & limits
what stays whereEverything runs in your browser. Your text is never uploaded; the reversal happens against an array in memory, with no network round-trip in between. After page load, the tool works offline. 80 MB hard cap per run.
Frequently asked
answeredHow is this different from sorting in descending order?
Sorting compares values; reversal flips the existing order. If your input is "apple", "banana", "cherry", reverse gives "cherry", "banana", "apple" — but if the input is "banana", "apple", "cherry", reverse gives "cherry", "apple", "banana" (not the descending sort).
Why not just use `tac` or `tail -r` on the command line?
You can — and if you live in a terminal, `tac file.txt` on Linux or `tail -r file.txt` on macOS is faster. This tool is for the 95% of people who don't open a terminal: paste, click, get the flipped list.
Does it preserve blank lines?
By default, blank lines come along for the ride and end up at the top of the flipped output. Toggle "remove blank lines" on if you want them stripped before flipping.
Is my data uploaded anywhere?
No. All processing runs locally in your browser tab. There is no server-side step; the page works offline after loading.