Document table extraction

narrowly leads for extracting structured tables from PDFs.

Since Jul 6Updated Nov 20, 2026Based on 96 AI answersReviewed by

How we measure

Brands AI mentions

#BrandMentioned in

For complex layouts, borderless tables, and multi-page document structures.

For inspecting character, line, and rectangle coordinates in PDFs.

For commercial API use with production support and enterprise needs.

For isolating tables as HTML or JSON in RAG and ETL workflows.

#5Docling19%
Mentioned in, on ChatGPT and Google AI Mode

Key takeaways for Document table extraction

  • Top contenders

    LlamaParse (57%) leads runner-up PDFPlumber (51%) by 6 percentage points.

  • Across AI Document Parsing & Extraction APIs

    Within AI Document Parsing & Extraction APIs, Regure leads Insurance claims data extraction, showing AI shifts picks by buyer use case. See Insurance claims data extraction

Questions and answers

  • ChatGPTNov 19, 2026

    1. 1Docling
    2. 2Azure AI Document Intelligence

    If you need a PDF parser that preserves actual table structure (rows, columns, individual cells, headers, and merged cells) rather than flattening everything into raw text, I would recommend Docling as the first option.

    Here are the strongest options I found.

    Best PDF parsers for structured table extraction

    • Information Extraction (Tests on a Beta API) from Docling | by Alain Airom (Ayrom) | Medium

    1. Docling

    (My top recommendation)

    • Open source.
    • Detects tables and reconstructs row/column relationships.
    • Supports merged cells and complex layouts.
    • Exports structured document representations, including JSON and HTML.
    • Supports OCR for scanned PDFs.

    Website:

    Documentation: Table structure options ·


    2. Azure AI Document Intelligence

    (Strong structured extraction)

    • Extracts individual table cells.
    • Preserves row and column indexes.
    • Supports row spans and column spans.
    • Provides cell coordinates and header identification.
    • JSON and HTML table output.

    Website:

    Particularly useful for enterprise document processing.


    • How to extract tables from PDFs with Camelot | Raj Balabantaray posted on the topic | LinkedIn

    3. Camelot

    • Specifically designed for PDF table extraction.
    • Extracts tables into individual cells.
    • Exports to DataFrames, CSV, JSON, and Excel.
    • Multiple extraction strategies for bordered and borderless tables.
    • Optional machine-learning and OCR support.

    Website:

    Best when your primary concern is extracting tables rather than understanding the entire document.

    Quick comparison

    CapabilityDoclingAzureCamelot
    Individual cellsYesYesYes
    Row/column relationshipsYesYesYes
    Merged cellsYesYesLimited
    Scanned PDFsYesYesWith OCR
    Full document structureYesYesNo
    Open sourceYesNoYes
    Local processingYesNoYes

    What I would choose

    • Docling: Best overall if you want a complete PDF-to-structured-data pipeline.
    • Azure Document Intelligence: Best if you want detailed cell-level extraction through an API.
    • Camelot: Best if you mainly need tables from digitally generated PDFs.

    One important question

    What are you building this parser for?

    1. LLM/RAG pipeline – feeding PDFs into an LLM without losing table relationships.
    2. Data extraction – converting PDF tables into JSON, Excel, or database records.
    3. Document understanding – preserving the entire document layout, including paragraphs, tables, headers, and footnotes.
    4. Agent pipeline – allowing an AI agent to read PDFs and understand which values belong to which table cells.

    The distinction matters because I would recommend a slightly different architecture depending on your answer.

    Google AI ModeNov 19, 2026

    1. 1PDFPlumber
    2. 2Docling
    3. 3LlamaParse

    Choosing the right PDF parser depends on whether your tables are digital-native (clean lines/text) or scanned/complex (merged cells, multi-line headers, weird borders) , and whether you want to run things locally or via the cloud.

    Top Recommendations by Use Case

    1. Best for Programmatic / Code-First Workflows (Open Source & Local)

    • pdfplumber
      • Best for: Precise geometric control, bounding boxes, and inspecting individual words/lines inside table cells.
      • How it works: Uses pdfminer under the hood to expose the exact (x, y) coordinates of every character, line, and rectangle.
      • Pros: Great for clean documents; gives you direct access to cell structure as nested Python data structures.
      • Cons: Complex tables with missing gridlines or weird shading require writing custom heuristics or fallback logic.
    • Camelot
      • Best for: Standard grid-based tables.
      • How it works: Offers two modes—Stream (detects tables via whitespace alignment) and Lattice (detects tables via explicit ruling lines).
      • Pros: Easily exports straight to a pandas DataFrame , JSON, or CSV.
      • Cons: Struggles heavily with multi-line cells, complex merged cells, or heavily styled/colored backgrounds.
    • Docling (by IBM)
      • Best for: Modern deep-learning/transformer-based local table parsing (powered by TableFormer).
      • How it works: Runs locally on your machine (CPU or GPU) to analyze layout, reading order, and table structure, exporting directly to Markdown, HTML, JSON, or pandas.
      • Pros: No API key required, high accuracy on complex documents, and handles mixed text-and-table layouts gracefully.
      • Cons: Heavy resource footprint on first run (downloads layout/OCR model weights).

    2. Best for High-Complexity / Messy PDFs (Cloud / LLM-Guided)

    • LlamaParse (by LlamaIndex)
      • Best for: Messy documents, heavily nested tables, scanned documents, or weirdly formatted multi-page schedules.
      • How it works: Cloud-based pipeline that uses vision/LLM intelligence to interpret page layouts and table relationships.
      • Pros: Outperforms almost all traditional heuristic parsers on weirdly structured, irregular, or non-standard tables.
      • Cons: Sends your data to the cloud (privacy/compliance consideration) and incurs per-page/tier usage costs.

    Quick Comparison Matrix

    ToolProcessingOutput FormatsBest Suited For
    pdfplumberLocal (Python)Python dicts / custom scriptsFine-grained coordinate & cell extraction
    CamelotLocal (Python)Pandas, CSV, JSONClean grid or line-bounded tables
    DoclingLocal (Python)Markdown, HTML, Pandas, JSONOff-line AI-driven layout & table reconstruction
    LlamaParseCloud APIMarkdown / Structured JSONComplex, messy, or scanned tables

    To help narrow down the best fit, tell me:

    • Are your PDFs text-native (searchable) or scanned images?
    • Roughly how many pages/tables are you processing?
    • Do you need to run this 100% locally for privacy, or is a cloud API okay?
  • Google AI ModeSep 20, 2026

    1. 1LlamaParse
    2. 2Azure AI Document Intelligence
    3. 3AWS
    4. 4Unstructured
    5. 5Datalab

    Here are the top document parsers specifically built to preserve table structure (as Markdown , HTML, or structured JSON) instead of flattening everything into unformatted text blocks:

    • LlamaParse - Powered by advanced vision-language models, it natively reconstructs complex tables, multi-column layouts, and hierarchical structures into clean Markdown. It is built directly for RAG workflows and structured document ingestion.
    • Azure AI Document Intelligence (formerly Form Recognizer) - Outstanding enterprise choice for heavy-duty table extraction. Its "Layout" and "Prebuilt" models extract tables with explicit row/column indices, cell spans, and confidence scores, outputting directly to JSON or markdown.
    • Marker - An open-source, high-speed PDF-to-Markdown/JSON converter that runs locally (ideal if you need data privacy or don't want a paid cloud API). It does a phenomenal job of recognizing tables and preserving text formatting without relying on heavy commercial cloud engines.
    • AWS Textract - The go-to tool if you are already in the AWS ecosystem. It has specialized table and form analysis features that return bounding boxes, cell coordinates, and table data in structured JSON format rather than a generic text block.
    • Unstructured - An open-source and hosted ingestion framework that partitions documents into structured elements (identifying titles, narratives, and tables separately) so you can export tables cleanly without losing context.

    To help narrow down the best fit, tell me:

    • Are you looking for a cloud API or an open-source/local tool?
    • What is your target output format (Markdown, JSON, or CSV)?
    • What kind of documents are you parsing (invoices, financial reports, academic papers)?

    ChatGPTSep 20, 2026

    1. 1Docling
    2. 2Unstructured

    Yes. If your requirement is “preserve tables as actual tables/structured cells rather than flattening everything into a text blob,” I’d look at these:

    • Docling — probably the closest match. It parses PDFs, DOCX, PPTX, XLSX, etc., and has a structured document model with explicit table/cell information. Its JSON representation preserves row/column spans, and HTML output preserves rowspan/colspan.
    • Unstructured — returns tables as distinct Table elements rather than only text. Importantly, it can provide an HTML representation in metadata.text_as_html, preserving rows and cells. For PDFs, you enable table structure inference.

    What I'd choose

    If you're building an LLM/RAG/document-understanding pipeline, I'd start with Docling and use its JSON or HTML output, rather than Markdown. Docling explicitly warns that Markdown cannot represent merged cells, while its JSON/HTML representations retain that structure.

    For example, instead of getting:

    Revenue Q1 $10M Q2 $12M Q3 $15M

    you want something conceptually like:

    {
      "type": "table",
      "rows": [
        ["Quarter", "Revenue"],
        ["Q1", "$10M"],
        ["Q2", "$12M"],
        ["Q3", "$15M"]
      ]
    }

    or an HTML <table> that retains the actual row/cell relationships.

    If you tell me what document types you're parsing (PDF, DOCX, scanned PDFs, Excel, etc.) and what output/API format you want (JSON, HTML, Markdown, Python objects, LLM-ready chunks), I can narrow this down to 2–3 parsers that fit your exact requirements.

Also asked as

  • Can you recommend a document parsing tool that preserves table structures instead of just outputting raw text?
  • What are the top API solutions for turning table information from scanned images or PDFs into structured data?

Document table extraction: common questions

Which brands does AI recommend for Document table extraction?
AI most often mentions LlamaParse (57%), PDFPlumber (51%), Azure AI Document Intelligence (35%), Unstructured (34%) and Docling (19%) for Document table extraction in AI Document Parsing & Extraction APIs.
What questions do buyers ask AI about Document table extraction?
Common buyer questions include "I need a PDF parser that respects table cell structures and does not just dump raw text.", "Can you recommend a document parsing tool that preserves table structures instead of just outputting raw text?", "What are the top API solutions for turning table information from scanned images or PDFs into structured data?".
For agents: this page as Markdown, parse.gl/topics/pdf-table-extraction.md.

This page

Reuse: Figures and tables on this page are free to republish with attribution: a link to https://parse.gl/topics/pdf-table-extraction beside them. A standard followed link (dofollow) is preferred.

Read and search

Every brand's share on this topic, with 95% ranges: GET agent.parse.gl/v1/tools/query_metrics?args=%7B%22measures%22%3A%5B%22share_named%22%5D%2C%22by%22%3A%5B%22brand%22%5D%2C%22filter%22%3A%7B%22topic%22%3A%5B%22top_d4e26d79-b3a7-4b50-aa5a-cdcaedb83e5c%22%5D%7D%7D
Search the index: GET parse.gl/api/public/search?q=<words>

Connect

Connect an assistant: agent.parse.gl/mcp

An agent can save work before signup: POST https://agent.parse.gl/v1/workspaces

What it costs

No account: Public figures and up to 5 examples per list, about 120 brands a day per address.
Free account: $5 in credit, your brand's first check (20 buyer questions) and a free weekly check.
After your first top-up: Exports and deeper search results. The first top-up starts at $5.
Live checks: $0.01 per question per engine ($0.05 on Gemini and Claude).
Full public answers and pages: 25 free per day, then $0.005 each.
Public answers older than 90 days: $0.001 each the first time your workspace counts or lists one, then yours.