Text / File Diff Tool
Plaintext & File DiffCompare arbitrary text files, code snippets, logs, markdown, and config files side-by-side or inline as plain text.
Complete Guide to Text & Code Difference Algorithms
Understand how Myers' diff algorithm and Longest Common Subsequence (LCS) calculate text revisions, whitespace normalization, and similarity percentages.
Comparing two text documents or code files to pinpoint exactly what was added, deleted, or modified is a cornerstone of version control systems like Git. Whether reviewing pull request changes, debugging application server logs, or inspecting environmental configuration files (.env, YAML manifests, NGINX configs), visual difference tools make changes immediately obvious.
At the core of modern diff tools is Myers' Diff Algorithm and the Longest Common Subsequence (LCS) problem. The algorithm finds the shortest sequence of edit operations (insertions and deletions) necessary to transform document A into document B.
Side-by-Side vs. Inline Diff Views
Side-by-Side (Split) view places the original document on the left and the modified document on the right, providing clear horizontal spatial context. In contrast, Inline (Unified) view combines both files into a single linear vertical stream, highlighting removed lines with a red background and added lines with a green background.
How to Use This Tool
Provide Original Text
Paste your base text or upload an original file into the left pane of the editor.
Provide Modified Text
Paste the updated or revised text or file into the right pane of the editor.
Adjust Comparison Settings
Toggle Ignore Whitespace or Ignore Case to filter out irrelevant formatting or capitalization differences.
Review Metric Breakdown
Inspect the similarity percentage, count of added lines, removed lines, and unchanged text segments.
Key Features & Capabilities
Monaco Diff Technology
Uses the same world-class diffing engine found inside Visual Studio Code.
Exact Similarity Metrics
Calculates exact Levenshtein and line-based similarity percentages between documents.
Whitespace & Case Controls
Easily ignore trailing spaces, tab differences, or casing when auditing code revisions.
100% In-Browser Privacy
Compare proprietary source code, credentials, or private logs without cloud upload.
Frequently Asked Questions
What is the difference between side-by-side and unified diff?
How is the similarity score calculated?
Can I compare programming languages other than JSON?
Are my text files sent to any remote server?
Privacy & Security Guarantee
All data processing, AST syntax repairs, and cryptographic operations happen 100% locally inside your browser using native JavaScript and WebAssembly. No inputs, keys, or file payloads are ever transmitted to or stored on remote servers.