Getting the Numbers Out of a Contract: PDF Tables to Excel

Getting the Numbers Out of a Contract: PDF Tables to Excel


The commercial terms of most agreements are not in the clauses. They are in the annexes: a payment schedule, a rate card, a table of service levels and the credits that apply when they are missed, a list of deliverables with dates.

Those tables are where the money is, and they arrive as pictures of tables inside a PDF. You cannot add up a column in a PDF.


Pull the tables out

PDF to Excel — upload the contract, get a workbook back with one sheet per table found. PDF to CSV does the same into a single file if you are feeding something else with it.

Two things worth knowing about what you get:

Figures arrive as numbers, not as text. This sounds like a detail and is the whole point. A column of amounts extracted as text cannot be summed, sorted, filtered or charted, and every cell carries a “number stored as text” warning. Here 22.5 is 22.5, 250,000 is 250000, and accounting’s (200,000) is −200000, so you can total a payment schedule the moment it opens.

What is not a quantity stays text. A fiscal year written 2009/10, a clause reference 12.5.1, an account number beginning 007 — reading any of those as a number would destroy exactly the part that mattered, so they come across as they were written.


What it can and cannot find

Table extraction works from the ruling lines and the alignment of the text. So:

  • A table with visible borders — reliable
  • A table with lines only between the header and body — usually fine
  • Columns made with tab characters and no lines at all — often not found

If nothing is found, the document will say so rather than hand you an empty workbook. In that case the fastest route is PDF to Word, which keeps table structure even where extraction cannot see a grid, and copying the table across from there.

Scanned annexes need OCR first — there is no table to find in a photograph.


What to do once it is in a spreadsheet

This is the part worth the five minutes, because these are the errors that survive review and turn up in an invoice dispute:

Total the payment schedule. Check it equals the contract value stated in the body. Schedules assembled by hand disagree with the headline figure more often than anyone expects.

Check the dates run in order and that there are no gaps or overlaps between periods.

Recalculate one line of every formula the annex claims. If the rate card says 40 hours at $85 is $3,600, the contract has an error in it and you found it before signing rather than at invoice.

Sort the deliverables by date and see whether anything is due before the contract starts. It happens.


Going the other way

If you are the one drafting, you probably have the schedule in Excel already. Excel to PDF puts the values into a document you can attach, and CSV to Excel turns an export from a billing system into a real workbook first.

Attach the PDF, not the spreadsheet. A workbook carries hidden sheets, formulas showing your cost basis, and the tab you forgot to delete.


And the clauses that govern the numbers

A payment schedule means very little without the clauses around it — late payment interest, the right to withhold, what happens on early termination, and whether the rates are fixed for the term.

Upload the whole contract for a free review and read the six scores with the reasoning for each. Clarity and Completeness is the one that catches a schedule referred to in the body but never attached, which is a surprisingly common way for a contract to have no agreed price at all.


Next step: pull the tables out → — free, no account.

Ready to simplify your legal document review?

Start using LegalValidate.ai to instantly analyze, validate, and improve your contracts and agreements.

Get Started for Free No credit card required. Try it now!

Keep reading

All guides → · The 25 free document tools → · Analyze a contract →