Regex Tester
Test JavaScript regular expressions live, with highlighted matches, capture groups, and find and replace.
Compare two texts or code snippets and see every difference. Free, private, and 100% in your browser.
Paste text into both editors to see the differences.
A diff checker shows what changed between two versions of a text. Paste the original on the left and the new version on the right: added lines are green, removed lines are red, and the changed words inside a line are highlighted. It is ideal for code reviews, comparing configuration files, spotting changes in contracts and documentation, and finding what differs between two log files.
--- original.txt
+++ modified.txt
@@ -2,3 +2,3 @@
1. Update the version number
-2. Deploy on Tuesday
+2. Deploy on Thursday
3. Publish the release notesRead changes in two aligned columns, or in a single column like git diff.
Inside changed lines, the exact words that were added or removed are highlighted.
Skip changes in indentation, trailing spaces, or capitalization to focus on real edits.
Copy or download the changes as a .diff file that works with git apply and patch.
Compare thousands of lines with the Myers diff algorithm, the same one used by Git.
Both texts are compared in your browser. Nothing is uploaded or stored.
No. The comparison runs entirely in your browser, so it is safe for source code, configuration files, contracts, and logs that contain private data.
It splits both texts into lines and uses the Myers diff algorithm to find the smallest set of added and removed lines. Changed lines are then compared word by word to highlight exactly what changed.
Yes. Enable Ignore whitespace to treat lines as equal when they differ only in spaces, tabs, or indentation. Enable Ignore case to ignore capitalization.
It shows the differences in unified diff format, the standard output of diff -u and git diff. You can download it as a .diff file and apply it with git apply or patch.
Yes, but our JSON Comparer and XML Comparer are better for structured data: they ignore formatting and key order and list every changed value by path.
Test JavaScript regular expressions live, with highlighted matches, capture groups, and find and replace.
Convert text and variable names to camelCase, PascalCase, snake_case, kebab-case, CONSTANT_CASE, and more.
Count words, characters, sentences, lines, and UTF-8 bytes as you type, with reading time and length limits.
Beautify, minify, and validate JSON instantly with exact line and column error reporting.