Docubox
ToolsPricingSecurityHelp
Sign inCreate free account
Docubox

Convert, organize, and protect your files.

Files are processed on our servers. Unsaved results expire 24 hours after upload. Saved documents stay until you delete them.

All toolsPricingHelpSecurityFile retentionStatusPrivacyTermsContact
Docubox
ToolsPricingSecurityHelp
Sign inCreate free account
Tools/PDF to CSV

PDF to CSV

Convert PDF to CSV by pulling the tables out of a text-based PDF into one file, with each table's page number and a confidence rating written above its rows. Docubox reads the PDF on its servers, and you sign in with a free account (Google or an emailed code, no password) to download the CSV.

How to convert PDF to CSV

  1. Add a PDF that contains real text. Drag it onto the upload box or choose it from your device; each run takes 1 PDF. If you can highlight a number in a PDF viewer, the text is there. A PDF that needs a password to open is refused.
  2. Check the options. They appear under the file once it is added. Output format is already CSV here, though the menu still offers XLSX, and Pages starts as all.
  3. Limit the pages if you only need some. Type one page number, such as 4, or a list like 1-3, 5. A range can be open at the end, so 7- reads from page 7 to the last page. Numbers count from the first page of the file, whatever is printed on the pages.
  4. Select Convert to CSV. The PDF goes to private storage and our servers examine it one page at a time, while a counter shows how many pages are done.
  5. Sign in, then download. Open a free account with Google or an emailed code, no password. The file is named after your PDF with -tables added, so statement.pdf gives statement-tables.csv. A CSV has no preview here, so open the download and compare it with the PDF. A note on the result page flags any table rated below high.
  6. Save it if you need it later. Save to my documents keeps a copy in your account beyond the temporary window.

When to use CSV vs PDF, and CSV vs XLSX

A PDF records where each piece of text sits on a page. Most PDFs do not store a table as rows and columns, so a converter has to infer the grid from positions, and the result deserves a check against the original. A CSV is the opposite kind of file: plain text, one line per row, commas between cells, readable by almost any spreadsheet, database or script.

  • Choose CSV for data headed into other software. Database imports, scripts, accounting and CRM uploads and Google Sheets commonly accept it once the comment rows described below are removed, and the file stays small and readable in any text editor.
  • Choose XLSX when a person will work in Excel first. An XLSX gives each table its own worksheet and adds a Review sheet listing every table's confidence. The same tool makes it: switch Output format, or open PDF tables to XLSX.
  • If you only want the words, skip tables. Text outside the tables never reaches the CSV. Extract PDF text pulls out a PDF's embedded text without trying to build a grid.

Things to know

  • Every table goes into one file. Each block starts with a comment row such as # page 2 table 1 (confidence high), then that table's rows, and a blank line separates blocks. Even a one-table CSV begins with a comment row, and no header row is marked: a table's first row is simply the first row found. Each comment row holds a single value, so a database or script that expects the same columns on every line may stop at it. Delete those rows and the blank lines, or tell your importer to skip them.
  • Confidence is written into those rows. A CSV has no room for a separate review sheet, so each table is rated high, medium or low in its comment row. The rating goes up when the table is mostly filled in, its rows share a shape and its lines are drawn on the page. A table found only by text alignment is medium at best, and low if a column boundary cuts through a word. It is a cue to check, not a measure of accuracy, and merged cells or nested tables can split or shift cells even in a table rated high.
  • Two ways of finding tables. Docubox looks first for tables drawn with ruling lines. Only when a page has none does it look for text lined up in columns, and it keeps those candidates only if they are at least half filled and do not cut through many words. Either way a table needs at least two rows and two columns. So on a page with a ruled table, a second table without lines is not picked up. If no page has a table, the run stops with a message that no tables with a text layer were detected, instead of giving you an empty file.
  • Scans have no tables to read. A scan is a picture with no text underneath. OCR to text reads printed English from one, but it returns plain text without rows or columns, so it cannot produce a CSV.
  • Values are copied as printed. Each cell is the text found in the PDF, trimmed at both ends and otherwise unchanged: dates stay as written, and 1,234.50 stays 1,234.50 but appears in quotes so its comma is not read as a separator. A cell that wraps over several lines in the PDF becomes a quoted field with a line break inside it. Spreadsheet apps show one cell, while tools that read line by line see extra lines. Empty cells stay empty, entirely empty rows are removed, and each table's rows are padded to the same width.
  • Plain numbers are untouched, and other text starting with = + - or @ gets an apostrophe. A cell that is only a number, signed or not, such as -12.75, +3, -1,234.50 or -8%, is written exactly as found. Any other cell that begins with =, +, - or @ gets a leading apostrophe so spreadsheet programs do not run it as a formula. That covers =SUM(A1), @name and -abc, and also a lone - that means zero or none, or a phone number such as +44 20 7946 0958. The result page then says formula-like values were written as literal text. The apostrophe stays in the cell as a character, so remove it if the CSV is going to a database.
  • Tables that cross a page break arrive in pieces, and short pieces can be lost. Each page is analyzed alone, so a table that continues on the next page gets a new comment row, and its header is not repeated unless the PDF prints it again. A leftover piece with only one row on its page falls under the two-row minimum and is skipped without a warning, so check the last rows of any table that spans pages.
  • Limits. A run takes one PDF of up to 25 MB and 50 pages. The page limit applies to the whole file even when you choose only a few pages, so cut a longer PDF down first with Split PDF, which accepts longer files. A PDF that only restricts printing or copying opens normally. A free account can run 10 conversions a day, and Pro costs $9.99 a month.

Frequently asked questions

Can I convert a scanned PDF to CSV?

No. A scan holds a picture of each page and no text, and this converter reads only embedded text, so it stops with a message that no tables were detected. OCR can recognize printed English in a scan, but it gives plain text without rows or columns, so the figures would need to be typed into a spreadsheet by hand.

How do I load the CSV into a database or script?

Delete the comment row above each table and the blank lines between tables, or have your importer skip them. Then load each table on its own, because tables can have different numbers of columns and the file does not label a header row. The first row of every table is simply the first row found in the PDF.

Can I get a separate CSV for each table?

Not from one run: the result is a single file with every table in page order. To separate the tables, split the CSV yourself at the blank lines, or switch Output format to XLSX, which gives each table its own worksheet. Running one page at a time with the Pages box also works, but each run counts as a conversion and tables on the same page stay together.

Why do accented letters look wrong when I open the CSV in Excel?

The file is UTF-8 without a byte-order mark, and Excel may guess a different encoding when you double-click it. In recent versions, open it through the Data tab and From Text/CSV, and choose UTF-8 as the file origin. Setting data type detection to off on that screen also keeps codes such as 00123 from losing their zeros. The text in the file is correct; only the way it was read needs changing.

Why do some cells start with an apostrophe?

Text that begins with =, +, - or @ and is more than a plain number gets an apostrophe so spreadsheet programs cannot run it as a formula. That includes a lone dash and phone numbers that start with +. A cell that is only a number, such as -12.75 or -1,234.50, is left exactly as printed, so negative amounts are not changed.

Is it free, and how long are my files kept?

Yes. A free account can run 10 conversions a day, and you sign in with Google or an emailed code to download the CSV. Pro costs $9.99 a month. Your PDF and the CSV are temporary: access ends 24 hours after you start unless you choose Save to my documents, and downloading does not delete or extend them.

More options

This page uses the PDF tables to XLSX tool with settings chosen for you. Open the full tool for every option.

Docubox

Convert, organize, and protect your files.

Files are processed on our servers. Unsaved results expire 24 hours after upload. Saved documents stay until you delete them.

All toolsPricingHelpSecurityFile retentionStatusPrivacyTermsContact
Sign inCreate free account

Free account required to view and download your result. No payment needed. Results are temporary for 24 hours unless saved.

Drop files here, or

PDF · up to 1 files, 25 MB total · processed on our servers