Find every text change between two versions of a PDF in seconds. Added lines are green, removed lines red, and changed lines show exactly which words were edited, with page numbers on both sides. Both files are read in your browser and never uploaded.
Similarity0%
Words added0
Words removed0
Changed lines0
Removed from AAdded in BEdited words in a changed line
Choose two PDFs to compare. The text of both files is extracted page by page and every added, removed or changed line is highlighted. Nothing is uploaded.
Advertisement
Advertisement
How to use the Compare PDF
Open the original PDF in the left box and the changed PDF in the right box (drop them or click to choose).
Press Compare PDFs. The text of every page is extracted and compared; this takes a second or two for most files.
Review the differences: green is added, red is removed, and changed lines highlight the edited words. Use Next change to jump through them.
Adjust the view: switch between side-by-side and inline, show only changes, or ignore case and spacing.
Save the result with Download report (HTML) or Copy differences.
How the comparison works
Text extraction. pdf.js reads the text layer of every page and rebuilds the lines from the position of each piece of text, so the result follows the reading order of the page.
Line alignment. The two documents are compared as a whole with the Myers difference algorithm (the same method used by git diff), which finds the smallest set of added and removed lines. Because the whole text is aligned, an inserted page does not throw off the rest of the comparison.
Word highlighting. When a removed line and an added line share at least 30% of their words, they are shown as one changed line and the algorithm runs again on the words, so you see exactly which words were edited.
Reading the results
Marker
Meaning
− red line
Line exists only in A (the original): it was removed.
+ green line
Line exists only in B (the changed file): it was added.
~ changed line
Line was edited. Struck-through red words were removed, green words were added.
A · page 2 ⟷ B · page 3
Where each side's lines come from, useful when pages were inserted or removed.
Similarity
2 × unchanged words ÷ (words in A + words in B).
Tips for accurate results
Keep Ignore extra spaces on. Different PDF producers place spaces differently, and this option hides changes that are only spacing.
Re-flowed paragraphs can show as changed lines even when the words are the same, because the line breaks moved. The word highlights show that nothing else changed.
Scanned documents need OCR first. To check what text a PDF contains, open it in PDF to Text.
To compare plain text or code you have already copied, use Text Compare.
Frequently asked questions
How do I compare two PDF files for differences?
Choose the original PDF on the left and the new version on the right, then press Compare PDFs. The tool extracts the text of both files, aligns them line by line and highlights what was added, removed or changed, down to individual words.
Does it compare images, formatting or layout?
No. This tool compares the text content. Changes to images, colors, fonts or exact positions are not reported, and a paragraph that only re-wraps differently can show as a changed line. For a visual check, open both files in the PDF Viewer side by side.
Can it compare scanned PDFs?
Only if the PDF contains a text layer. Scanned pages are pictures, so there is no text to compare; the tool tells you when a file has no selectable text. Run the scans through OCR software first and then compare.
What happens if pages were added or removed?
The comparison runs over the whole document, not page against page, so an inserted page shows up as added lines and the rest of the document still lines up correctly. Page numbers on each side show where each line comes from.
How is the similarity score calculated?
Similarity = 2 × unchanged words ÷ (words in the original + words in the changed file), shown as a percentage. Identical text scores 100%, and two texts with nothing in common score 0%.
Are my PDFs uploaded to a server?
No. Both files are opened with pdf.js inside your browser tab and compared on your device, so confidential contracts and reports never leave your computer.
Is there a size limit?
There is no fixed limit, but very long documents with thousands of changes take more memory. Documents of a few hundred pages compare in seconds on a typical computer.