How to compare two versions of a PDF without printing both
Someone sends you revision 4 and asks what changed. Reading both side by side works until page 60, and then you start missing things. A diff is the right tool, provided you know what it is comparing.
Two kinds of difference
A visual comparison treats each page as a picture and highlights pixels that moved. It catches a logo shifting two millimetres, a signature appearing, a table restyled. It cannot tell you what the new sentence says, and it goes completely silent on two pages of identical-looking text where one number changed from 30 to 60.
A text comparison extracts characters from both files and compares the words. It finds every comma that moved and every clause that was reworded, and it is blind to anything that happened without changing text.
Neither is better. They answer different questions, and most arguments about diff tools are people using one and expecting the other.
How the text comparison works
The usual approach is a line diff. Both documents are split into lines, matching lines at the start and end are trimmed away because they cannot have changed, and the remainder is compared to find the smallest set of additions and deletions that turns one into the other.
Trimming the unchanged head and tail is what keeps this fast. Without it, comparing two sixty-page contracts means a grid of 3,600 by 3,600 comparisons; with it, only the pages that differ cost anything. Very large changed regions need a fallback, usually reporting the whole block as replaced rather than pretending to trace it line by line.
Where a text diff reports nothing when something changed
If either file is a scan, there is no text to compare and every line looks new or the result is empty depending on the tool. Check that both files have a text layer first.
If the text was reflowed but not edited, for example the same paragraph re-wrapped narrower, every line breaks somewhere else and the diff shows a rewrite that is only layout. Some tools normalise whitespace and re-wrap before comparing; if yours does not, read the diff as words rather than lines.
If content moved between pages, a page-by-page diff shows a deletion on page 12 and an addition on page 13 with no indication they are the same paragraph. Page-level comparisons are easier to read and worse at this than whole-document comparisons.
A workflow for reviewing a redlined contract
- Confirm both files are text PDFs by selecting a sentence in each.
- Compare the whole document rather than page by page, so moved paragraphs stay recognisable.
- Read only the additions first. Deletions matter, but additions are where new obligations appear.
- Check every number, date and defined term in the diff, even when it looks unchanged; these are the changes that get missed.
- Compare against the version you actually signed, not the one you remember agreeing to.
What a diff will not do
It will not tell you which version is correct, and it will not notice that both versions are wrong in the same way. It also cannot see meaning: replacing 'may' with 'shall' is a two-character change that alters the contract more than a rewritten paragraph elsewhere.
For anything binding, the diff narrows where a human should look. That is a large saving on sixty pages and no substitute for the human.