PDF to CSV converter
Pull the tables out of a PDF as CSV, one row per line and every value in its own column, ready for a spreadsheet, an import or a script. Converted on your device.
Choose a PDF. Its tables are read on your device and written out as CSV.
What was found is reported here.
Why CSV, and why not just copy the text
CSV is the format every tool that handles data can read: Excel and Google Sheets, but also accounting software importing a bank feed, databases loading a table, Python and R scripts, budgeting apps. It is plain text, one line per row, fields separated by commas. Copying text out of a PDF viewer gets you the words, but in whatever order the file drew them, with columns smeared together by spaces and no way to tell a gap inside a description from a gap between two fields. This page reads where each piece of text sits on the page and rebuilds the rows and columns before writing a single line of CSV.
Rows come from baselines: text on the same line is one row, whatever order the PDF drew it in. Cells come from horizontal gaps wider than about a letter. Columns come from the vertical strips of the page that no row writes in, worked out across every page at once so that the fourth field of a row on page 6 is the same field as the fourth field on page 1. Where a statement prints the date and the description almost touching, the shared left edge of the descriptions is used as a column boundary too.
Quoting, separators and Excel
A CSV file is only as good as its quoting. A merchant called SMITH, JONES & CO contains a comma; a note can contain a double quote or a line break. Each such field is wrapped in double quotes and any quote inside it is doubled, exactly as RFC 4180 specifies, so every program that reads standard CSV gets the same columns back. Fields with leading or trailing spaces are quoted as well, because some importers trim unquoted whitespace.
Excel has two habits worth knowing about. In much of Europe it expects semicolons, because the comma is the decimal mark there; if a comma-separated file opens with everything in column A, choose Semicolon and download again. And without a byte-order mark at the start of the file, Windows Excel assumes the text is in an old Western code page and shows é as é and € as €. The mark is three invisible bytes that tell it the file is UTF-8; it is on by default. Turn it off for tools that choke on it, which some command-line programs and older importers do. Tab separation writes a .tsv file, which pastes cleanly into any spreadsheet and never needs quoting for commas.
Plain numbers
By default every value is written exactly as printed: $1,234.56, (50.00), 50.00-. That is the faithful choice, and Excel itself understands most of those when it opens the file. Many importers do not, so Plain numbers rewrites amounts as bare values a program can read without guessing: currency symbols and thousands separators are removed, and the accounting ways of writing a negative, brackets or a trailing minus, become a leading minus sign. The number of decimal places is kept, so 12.50 stays 12.50. Values that only look numeric are left alone: anything with a leading zero (ZIP codes, account numbers), anything longer than 15 digits, percentages and dates.
If what you actually want is a spreadsheet, the PDF to Excel converter goes one step further and writes real number and date cells with formats, deciding day-first or month-first per column. For moving the data into code, CSV to JSON takes the file from here.
Limits
A scanned PDF contains no text and gives no rows; the report names the pages without a text layer. Tables drawn with ruled lines and no white space between cells may need Narrow gaps. Two tables printed side by side share columns and come out on the same rows. Text that is not part of any table, such as headings, addresses and small print, still comes through as one-field rows, so you can see everything that was on the page and delete what you do not need, rather than wondering what was dropped.
Common questions
Is the PDF sent to a server?
No. The file is read and the CSV is written by this page in your browser. Nothing is uploaded, which matters for the documents people most often convert: statements, payslips and invoices.
My CSV opens in Excel with everything in column A.
Your Excel uses a semicolon as the list separator, which is normal in most of Europe. Choose Semicolon under Separator and download again, or open the comma file through Data › From Text/CSV and pick the comma there.
Accented letters look wrong when I open the CSV.
Keep Start with a byte-order mark ticked. Without it, Windows Excel reads the UTF-8 file as an older Western encoding and turns é into é. Google Sheets, Numbers and LibreOffice read UTF-8 correctly either way.
What does Plain numbers do?
It rewrites amounts like $1,234.56, (50.00) and 50.00- as 1234.56, -50.00 and -50.00, so accounting software and scripts can read them without understanding currency symbols or bracket negatives. Leading-zero codes and long IDs are left alone.
Can I get one CSV per page?
Yes: choose One CSV per page under Files and you get a ZIP with a file for each page, named after the PDF and the page number. Pages with no text are skipped.
How are commas inside a field handled?
The field is wrapped in double quotes, and any double quote inside it is written twice. That is the RFC 4180 rule every spreadsheet and CSV library follows, so a description with a comma stays one field.
Does it read scanned statements?
No. Scanned pages are images with no text in them, and there is no OCR here. The report under the preview lists which pages had no text layer.
Why are the page headers missing from the CSV?
Lines that repeat on most pages at the same height, such as the bank's name and page numbers, are dropped, and repeated column headings are kept only once. Untick Drop page headers if you need them.