Diff Checker

    Compare two texts side-by-side and highlight the differences.

    Dialect
    Original Text
    New Text

    About Diff Checking

    A Diff Checker calculates the difference between two files or text blocks. Green lines indicate additions, while red lines indicate deletions. It's essential for code reviews, finding bugs, and tracking changes.

    Features

    • Side-by-side comparison
    • Split and unified result views
    • Privacy focused (runs locally)
    • Diff algorithm: LCS (Longest Common Subsequence)

    How the comparison works

    The tool compares text line by line. Any line that differs, even by a single character, is marked as removed from the original and added in the new version. Split view places the two versions in side-by-side columns with their own line numbers, and Sync Scroll keeps both columns aligned. Unified view lists every line in one column with - and + markers and both line numbers, similar to the output of git diff.

    When to use it

    • Comparing two versions of a config file, API response or log excerpt.
    • Checking a change to a file that isn't under version control.
    • Seeing what an editor changed between two drafts of documentation.

    Tips for cleaner diffs

    • Whitespace counts. Trailing spaces, changed indentation, and Windows (CRLF) versus Unix (LF) line endings all show up as changed lines, so normalize them first if you only care about content.
    • Format structured data before comparing. Minified JSON sits on a single line, so one edited value marks the whole document as different; pretty-print both sides first so the diff points to the exact lines.

    Frequently Asked Questions

    Is my data secure?
    Yes. This tool runs entirely in your browser. Your data is never sent to a server.
    How does it work?
    It uses the "diff" algorithm (O(ND) complexity) to find the smallest set of deletions and insertions to transform one text into another.