Text Diff
Compare two texts line by line with a side-by-side view and a git-style unified diff, powered by a fast LCS algorithm. Runs entirely in your browser.
Inputs
How it works
- The two texts are split into lines and aligned with a longest-common-subsequence (LCS) dynamic program, which finds the minimal set of insertions and deletions.
- The side-by-side view colors removed lines red and added lines green, with unchanged context in between; the unified view follows the git diff format with hunk headers.
- Documents up to 5,000 lines per side run through the full LCS table; anything larger falls back to a fast line-by-line comparison so the page never freezes.
- Everything runs locally — config files, logs, and private snippets never leave your device.
About Text Diff
A good diff shows not just that two texts differ, but exactly where and how. Line-based comparison is the right granularity for configuration files, server logs, generated code, or any change review: a single moved block reads clearly as removed-plus-added instead of a wall of red.
Use this tool to sanity-check config changes before deploying, to review what a teammate actually changed in a pasted snippet, or to build a patch you can paste into a PR description. Because the comparison happens on your machine, even confidential log excerpts or private configs can be diffed safely.