Diff with letter case folded out
Case-insensitive diff is the standard line diff with one tweak: equality is checked after lowercasing both sides. Internally the tool calls String.prototype.toLowerCase() on each pair of lines and compares the results. If they match, the line is emitted with its original casing (from text A); if they differ, the standard - A line followed by + B line pair is produced with both originals preserved.
The split between text A and text B is a line containing exactly ---. Pairing is positional, like the regular line diff: line 1 of A is compared to line 1 of B, line 2 to line 2, and so on. Inserting a line in B will shift indices and cascade as a string of changes; this is the same trade-off as the case-sensitive version.
Whitespace and punctuation are still significant. Hello and HELLO match, but Hello, and Hello do not because the comma is content. For full punctuation tolerance run a remove punctuation pass first; for word-level rather than line-level diff see word diff.
How to use case-insensitive diff
- 1Paste text A into the input panel, then a line with
---, then paste text B. - 2The case-folded diff appears in the output panel; matched lines keep their original casing, changed lines show both versions.
- 3Click Copy to copy the diff, or Download to save it as a
.txtfile. - 4Compare the result with case-sensitive diff to spot changes that are casing-only.
- 5For sub-line granularity pivot to word diff or character diff.
Keyboard shortcuts
Drive TextResult without touching the mouse.
| Shortcut | Action |
|---|---|
| Ctrl F | Open the find & replace panel inside the input Plus |
| Ctrl Z | Undo the last input change |
| Ctrl Shift Z | Redo |
| Ctrl Shift Enter | Toggle fullscreen focus on the editor Plus |
| Esc | Close find & replace, or exit fullscreen |
| Ctrl K | Open the command palette to jump to any tool Plus |
| Ctrl S | Save current workflow draft Plus |
| Ctrl P | Run a saved workflow Plus |
How the case-folded diff works
Lowercase comparison, original output
Lines are lowercased before equality check, but the output preserves the original casing from text A. So Hello World and HELLO WORLD match and the output reads Hello World.
Position-based pairing
Line 1 of A is compared to line 1 of B, line 2 to line 2, and so on. No fuzzy alignment. Inserting a line at the start of B shifts every subsequent index.
Whitespace and punctuation matter
Only letter case is folded out. Hello, versus hello still registers as a change because the comma is content. Strip punctuation first with remove punctuation if you want fuller tolerance.
Three-hyphen separator
The split between A and B is a line containing exactly ---. The tool needs this marker to know where text A ends and text B begins.
Plain-text output with -/+
Output uses two-space prefix on matched lines, - on the A version of changed lines, and + on the B version. Same shape as the standard line diff, just with case folded.
Worked example
Both lines match after lowercasing, so they pass through with their original casing from text A. Switch to case-sensitive diff to see the casing changes called out.
Hello World Quick brown fox --- hello world Quick BROWN fox
Hello World Quick brown fox
Settings reference
| Behaviour | Effect on output |
|---|---|
| Separator | A line containing exactly --- splits text A from text B. |
| Match rule | Equality after toLowerCase() on both sides. |
| Output for matches | Two-space prefix, original casing from text A. |
| Output for changes | - A-line followed by + B-line, both originals. |
| Whitespace | Significant. Spaces, tabs, and trailing whitespace count. |
| Punctuation | Significant. Letter case is the only thing folded out. |
| Missing separator | Output prompts for two halves split by ---. |
FAQ
Does it ignore everything case-related, including accented letters?
toLowerCase(), which follows Unicode case mapping. Latin accented letters fold cleanly (É matches é); Turkish dotted-I needs locale-aware handling that this tool does not configure. For pure ASCII case folding, that detail does not matter.How is this different from regular line diff?
Are punctuation differences still flagged?
Hello, and hello still register as a change because the comma is content. Run a remove punctuation pass first to drop punctuation before diffing.Which casing does the matched-line output use?
Hello and B has HELLO, the matched line in the output reads Hello.