← BlogGuides

PDF to Excel: Getting Tables Out Without Retyping Them

PDFalot Editorial Team·June 2, 2026·12 min read
Guides illustration for the article: PDF to Excel: Getting Tables Out Without Retyping Them

Why table extraction fails, how to tell a real table from a visual one, and how to clean the output in five minutes.

There are no tables in PDF. That is the whole problem in one sentence. A PDF stores glyphs at coordinates; a table is something a human infers from the arrangement of those glyphs. Extraction software has to reverse-engineer a structure that was never recorded.

Two kinds of table, two different jobs

Ruled tables

Tables with visible borders are the easy case. The rules are drawn as vector lines, so the extractor can detect the grid geometrically and assign each text run to a cell. Accuracy on clean ruled tables is very high.

Whitespace tables

Financial statements and reports often use alignment alone. The extractor has to cluster text by x-position and guess column boundaries. This works well until a single cell wraps to two lines, or a value is missing, or a column is right-aligned while its neighbour is left-aligned. Then rows shift.

The failure modes you will actually see

  • Merged headers spanning two columns collapse into one cell.
  • Multi-line cells split into separate rows.
  • Numbers in parentheses — accounting negatives — import as text, not as -1234.
  • Thousands separators and currency symbols make the whole column text.
  • Footnote markers glued to values: '1,204a' instead of 1204.
  • Repeated page headers appearing mid-dataset every 40 rows.

A five-minute cleanup routine

  1. Sort by the first column and look for rows that are obviously fragments of the row above — those are your wrapped cells.
  2. Find and remove repeated header rows in one pass.
  3. Select each numeric column and check the sum against a total printed in the source document. If it matches, the column is clean. This one check catches nearly everything.
  4. Convert accounting negatives: replace parentheses with a minus sign, then re-type the column as number.
  5. Strip currency symbols and separators before conversion, not after.

When the source is a scan

If your PDF is a scan, extraction is OCR first and table detection second, and errors compound. Digits are the highest-risk characters because no dictionary catches them. For scanned financial data, always reconcile against a known total; never trust the output on inspection alone.

The workflow that saves the most time

Extract, then verify with a sum, then clean. Most people clean first and verify last, which means they spend twenty minutes tidying a table that turns out to have dropped a row. One checksum up front tells you whether cleanup is worth starting.

A worked example: a three-column expense table

Take a typical scanned expense report with columns for Date, Description and Amount, twenty-two rows, and a printed total of 14,382.55 at the bottom. After extraction into a spreadsheet, sum the Amount column immediately with a formula in an empty cell below it. If the result is 13,208.12, you are missing rows, not making a typo error — go looking for a merged row or a row that got attached to the header block, rather than re-checking every digit by eye.

In this example the shortfall of 1,174.43 matched exactly one missing line item: a row whose description wrapped onto two lines in the source PDF, which the extractor had split into two separate table rows, one with the date and description and an empty amount cell, and one with just the amount sitting on its own line below. The fix took ten seconds once the checksum pointed at it directly: merge the two rows and delete the orphan.

Column-type mistakes that survive a visual check

A spreadsheet cell can look exactly like a number and still be text underneath, and Excel gives no visual cue at default zoom. Extracted currency columns are the most common victim: a value like $1,204.00 imports as a text string, right-aligns because Excel is being generous, and then silently drops out of any SUM formula that includes it. The formula returns a number that is quietly missing every affected row, and because the display still looks like a plausible total, nobody notices until a reconciliation fails weeks later.

  • Select the column, use Data > Text to Columns and click Finish — this forces a re-parse and converts genuine numeric text.
  • Multiply the whole column by 1 in a helper column as a lightweight numeric-coercion trick.
  • Watch for a small green triangle in the corner of a cell, Excel's own flag for 'number stored as text'.
  • Never trust a right-aligned currency column as proof it is numeric; alignment is cosmetic and survives conversion regardless of underlying type.

Dealing with merged and spanning headers

Reports that group columns under a shared header — for instance 'Q1' spanning three sub-columns for January, February and March — nearly always extract with that shared header attached to only the first sub-column, leaving the other two blank. The practical fix is to build the header row manually after extraction rather than trust the extractor's guess: type out the full column names once, save that header row as a template, and paste it over the top of every subsequent export from the same source document family. This is faster than debugging the extractor's spanning logic each time, and it is far more reliable.

Troubleshooting checklist before you accept an extraction

  1. Row count: does the extracted row count match a visible count in the source, or a stated count such as 'Table 4: 37 line items'?
  2. Column count: did any row silently gain or lose a column relative to its neighbours, which usually means a value bled across a column boundary?
  3. Checksum: does at least one numeric column sum to a total printed somewhere in the source document?
  4. Type check: are numeric columns actually stored as numbers, not text — check with a SUM formula, not by eye?
  5. Header integrity: does every column have exactly one header, with no spanning header duplicated or dropped?
  6. Encoding: do currency symbols, accented characters and footnote markers appear correctly, or as replacement boxes?
"If it cannot be reconciled to a total that already exists in the source document, treat the extraction as a draft, not a dataset."

Why OCR-based extraction and native extraction disagree

A native, text-based PDF stores each character with its own coordinates, so a table extractor is working from ground truth about where every glyph sits. A scanned page has no such ground truth — OCR first has to decide what each blob of pixels is, which introduces a second layer of guessing on top of the layout-inference problem every table extractor already faces. This is why the same extraction tool can produce a near-perfect result on a native PDF and a visibly broken one on a scan of the identical layout: it is not solving the same problem twice, it is solving a harder problem the second time.

Locale formatting differences that quietly break imports

Documents produced outside a US locale often use a comma as the decimal separator and a period or space as the thousands separator — the reverse of US convention. A value like 1.234,56 imports cleanly as text but, depending on your spreadsheet's regional settings, either fails to convert to a number at all or converts to the wildly wrong value 1234.56 read as 1,234.56. Before converting any column pulled from a European, South American, or South African source document, check one known value against the source rather than assuming your spreadsheet's default locale matches the document's.

A quick locale sanity check

Pick the largest number visible in the source table and compare it, character by character, with the same cell after extraction and conversion. If the decimal point has moved, or the value is exactly 1000 times too large or too small, you have a locale mismatch, not a general extraction failure, and the fix is a find-and-replace on separators before you re-run the numeric conversion, not a re-extraction.

Try it on your own PDF

Upload a document and put these ideas to work in under a minute.

Open PDFalot →

Keep reading

Try AI Now