±
Developer
Diff Checker FAQ — Compare Text, Code & Files Online
Answers about text comparison, diff algorithms, merge conflicts, and how to compare code and documents online.
Q1 How do I compare two texts online?
Paste original and modified text into the Diff Checker. Differences are highlighted instantly — green for additions, red for deletions. No signup required.
Q2 What is a diff?
A diff shows differences between two texts or files — which lines were added, removed, or changed. Fundamental to version control and code review.
Q3 What is a side-by-side diff?
Side-by-side shows original and modified in two columns with aligned line numbers. Easier to read for large changes. Default in GitHub and VS Code.
Q4 What is a unified diff?
Unified diff shows changes in a single column with + for additions and - for deletions. Default
git diff format. More compact than side-by-side.
Q5 How do I compare files in git?
Working vs staged:
git diff. Staged vs commit: git diff --staged. Between commits: git diff abc123 def456. Between branches: git diff main..feature.
Q6 How do I resolve a merge conflict?
Find conflict markers, choose the correct version (or combine both), remove markers, git add, git commit. VS Code has a visual merge editor.
Q7 How do I compare JSON files?
Sort keys first:
diff <(jq -S . a.json) <(jq -S . b.json). Or use the Diff Checker after formatting both with the JSON Formatter.
Q8 What diff algorithm does git use?
Myers' algorithm by default. Also available: patience (better for code), histogram (faster patience variant), minimal.
Q9 How do I compare branches in GitHub?
URL:
github.com/owner/repo/compare/base...compare. Shows all commits and file diffs. Can create a PR from this view.
Q10 How do I ignore whitespace in diffs?
Q11 How do I compare files in VS Code?
Right-click first file: Select for Compare. Right-click second: Compare with Selected. Or use Source Control panel for git changes.
Q12 What is a three-way merge?
Compares two modified versions against their common ancestor. If only one side changed a line, that change is accepted automatically.
Q13 How do I compare Word documents?
In Word: Review then Compare. For plain text: copy content into the Diff Checker.
Q14 What is a semantic diff?
A semantic diff understands code structure (AST-based) rather than comparing raw text. Can detect moved functions or renamed variables. Tools: difftastic, GumTree.
Q15 How do I generate a patch file?
Git:
git diff > changes.patch. Apply: git apply changes.patch. Patches share changes without pushing to a remote.
Q16 How do I compare directories?
CLI:
diff -rq dir1/ dir2/. GUI: Beyond Compare, Meld, WinMerge.
Q17 How do I view git diff in a browser?
GitHub: any commit URL shows the diff. PR diffs: github.com/owner/repo/pull/123/files.
Q18 What is cherry-picking in git?
Applies a specific commit from one branch to another:
git cherry-pick abc123. Use for backporting bug fixes.
Q19 How do I compare CSV files?
For small CSVs: use the Diff Checker. For large CSVs: use csvdiff or pandas DataFrame.compare().
Q20 What is interactive rebase?
Interactive rebase lets you edit, reorder, squash, or drop commits. Use it to clean up commit history before merging a feature branch.
Free Developer Tools
All tools run in your browser — no signup, no data sent to servers.