Compare Two PDF Files
This tool compares the readable text of two PDF files and shows you a line-by-li
This tool compares the readable text of two PDF files and shows you a line-by-li
How to use Compare Two PDF Files
- Choose your original PDF as file A and the revised PDF as file B.
- Optionally turn on ignore case or ignore spacing to focus on meaningful edits.
- Review the added, removed, and unchanged lines, then copy the diff if you need to share it.
About Compare Two PDF Files
This tool compares the readable text of two PDF files and shows you a line-by-line difference, so you can quickly see what changed between an original and a revised version. It extracts the text from each PDF using an in-browser PDF engine, reconstructs the lines, and runs a standard longest-common-subsequence diff to mark which lines were added, removed, or left unchanged. You also get a quick summary count of added, removed, and unchanged lines, plus page and word counts for each file, and a clear warning if a file has no selectable text to compare.
Everything runs privately in your browser. Both PDFs are read locally with JavaScript and are never uploaded to a server, so you can compare contracts, drafts, invoices, or reports without sharing them. You can toggle "ignore case" and "ignore spacing" to focus on meaningful edits, and copy the full diff to paste into an email or document.
Because it compares extracted text, it works best on PDFs with real, selectable text (exported from Word, Google Docs, or similar). It does not compare fonts, colors, images, or exact visual layout, and it cannot read scanned or image-only PDFs that have no text layer, or password-protected files. Text order is reconstructed from each item's position, so heavily columned or unusually laid-out pages may not line up perfectly.
Frequently asked questions
- How does it compare the two PDFs?
- It extracts the selectable text from each PDF, rebuilds the lines from their positions on the page, and runs a line-by-line diff. Lines marked with a minus are only in the original (A); lines marked with a plus are only in the revised file (B).
- Are my PDF files uploaded anywhere?
- No. Both files are read and compared entirely in your browser using JavaScript. Nothing is uploaded, stored, or sent to any server, so it is safe for private or confidential documents.
- Will it work on scanned PDFs?
- No. Scanned or image-only PDFs have no text layer to extract, so there is nothing to compare. The tool tells you when a file has no selectable text. It needs PDFs with real, selectable text, and it cannot open password-protected or encrypted PDFs.
- Does it detect formatting, image, or layout changes?
- No. It compares the readable text only. Changes to fonts, colors, spacing, images, or exact visual layout are not detected. Use the 'ignore case' and 'ignore spacing' options to focus the comparison on meaningful wording changes.
- Why do some lines show as changed when the wording looks the same?
- Text lines are reconstructed from each character's position on the page, so different spacing, column layouts, or line breaks can shift how lines are grouped. Turn on 'ignore spacing' to reduce false differences caused by layout.
- Can I save or share the differences?
- Yes. Use the Copy diff button to copy the full comparison as text, with plus and minus markers, so you can paste it into an email, chat, or document.