IBM Research & LF AI & Data Project

Docling: Ultra-Fast Document Parsing & AI Ingestion Engine

Docling simplifies complex document conversion by parsing PDFs, Office documents, images, and audio into structured Markdown and JSON format. Designed specifically for Generative AI applications, Retrieval-Augmented Generation (RAG), and agentic workflows.

bash — quickstart
$ pip install docling
$ docling https://arxiv.org/pdf/2408.09869 --to md
# Successfully parsed PDF and exported structured Markdown output to ./2408.09869.md

What is Docling?

Docling is an open-source document conversion and layout analysis engine developed by IBM Research and maintained under the LF AI & Data Foundation. It automatically converts heterogeneous document formats — including complex PDFs, Microsoft Word (DOCX), PowerPoint (PPTX), Excel (XLSX), HTML, EPUB, scanned images, and audio media — into unified, structured formats like Markdown, HTML, and JSON. Powered by Granite Docling (IBM's open-source vision language model) and TableFormer, Docling provides industry-leading PDF layout recognition, table structure extraction, reading order recovery, and seamless RAG pipeline integration.

Built for Modern AI & Data Engineering

Everything you need to turn raw documents into clean, structured data for LLM context windows.

Multimodal Document Parsing

Parse PDF, DOCX, PPTX, XLSX, HTML, EPUB, AsciiDoc, LaTeX, CSV, audio tracks (WAV, MP3), and domain XML (USPTO patents, JATS papers, XBRL reports) with a unified, expressible pipeline API.

PDF DOCX PPTX XLSX Audio (ASR) USPTO XML

Layout & Reading Order

Docling understands multi-column scientific layouts, sidebars, headers, footers, and visual reading hierarchy automatically.

Multi-Column Bounding Boxes

TableFormer Engine

State-of-the-art table structure extraction model accurately reconstructs complex merged cells and borderless financial tables.

TableFormer v2 HTML Tables

Pluggable OCR Support

Choose between EasyOCR, Tesseract, RapidOCR, OcrMac, or NVIDIA Nemotron OCR to extract text from scanned documents.

EasyOCR Tesseract RapidOCR

Native RAG HybridChunker

Chunk documents natively on structural nodes instead of character tokens, preserving header hierarchy, tables, and bounding box metadata.

HybridChunker Vector Stores

Unified DoclingDocument & AI Ecosystem

Convert documents into lossless `DoclingDocument` JSON structures, or export directly to Markdown and DocTags. Features native integrations with LangChain, LlamaIndex, Haystack, CrewAI, DSPy, and Model Context Protocol (MCP).

LangChain LlamaIndex Haystack MCP Protocol FastAPI Serve

Install Docling for Your Platform

Docling runs locally on Windows, macOS (Apple Silicon & Intel), and Linux (x86_64 and ARM64).

Install via pip
$ pip install docling
# Optional extras: pip install "docling[asr,vlm,easyocr,tesserocr]"
Install via Astral uv
$ uv add docling
Run via Quay.io Container
$ docker run -it --rm -v $(pwd):/docs quay.io/ds4sd/docling:latest docling /docs/sample.pdf
Claude Desktop / LM Studio MCP Server
// Add to claude_desktop_config.json or mcp.json
uvx --from=docling-mcp docling-mcp-server
macOS x86_64 Intel PyTorch Fix
$ pip install "docling[mac_intel]"
Linux PyTorch CPU Index
$ pip install docling --extra-index-url https://download.pytorch.org/whl/cpu

Platform Compatibility Matrix

Platform / Target Installation Method Recommended Extra / Command GitHub Release Link
Python Package Index (PyPI) pip / uv pip install docling v2.115.0 Release
macOS (Apple Silicon M1/M2/M3/M4) Native PyTorch (MPS) pip install "docling[ocrmac]" Source Zip
Linux x86_64 (NVIDIA CUDA) PyTorch CUDA 12 / 13 pip install "docling[vlm,asr]" Asset Direct
Windows 11 / 10 (x64) Python 3.9 - 3.14 pip install "docling[easyocr]" Asset Direct
REST API Container Docker / Podman quay.io/ds4sd/docling-serve docling-serve v1.21.0

Docling vs Alternatives

How Docling compares to other document conversion tools in the AI ingestion space.

Unlike legacy text extractors like PyPDF or pdfplumber which only dump unstructured text strings without reading order, Docling performs comprehensive visual layout analysis, reading order recovery, and table structure reconstruction via TableFormer. Compared to Unstructured.io, Docling runs 100% locally without forced cloud API dependencies, offers native audio transcription capabilities, and integrates directly with Model Context Protocol (MCP) servers.

Is Docling an OCR engine? Docling is not a standalone raw OCR engine like Tesseract, PaddleOCR, or EasyOCR. Instead, Docling is a higher-level document understanding and orchestration framework that plugs into and wraps OCR engines under the hood. While raw OCR engines only extract text strings from cropped image pixels, Docling adds neural layout detection, multi-column reading order recovery, TableFormer matrix extraction, and exports structured Markdown and JSON for LLM RAG pipelines.

Feature / Metric Docling (v2.115) Unstructured.io PyPDF / pdfplumber Marker
Complex PDF Layout Analysis
Table Structure Recognition (TableFormer) Partial / Paid API Basic Box Grid
Audio / Video Transcription (ASR) (Whisper)
Model Context Protocol (MCP) Server (Native)
100% Free Open Source (MIT) Apache 2.0 / Commercial BSD / MIT GPL v3 / Commercial
Self-Hosted REST API (`docling-serve`) Paid / Complex
Formula & Code Enrichment Partial

Quick Command Cheatsheet

Copy-pasteable CLI commands for common document conversion tasks.

Convert Single PDF to Markdown

Convert a local PDF file and save output directly to Markdown format.

docling report.pdf --to md
Convert Remote URL Document

Download and parse an online document directly from an HTTP URL.

docling https://arxiv.org/pdf/2408.09869
Force Full-Page OCR

Force OCR engine over entire pages regardless of existing PDF text.

docling scan.pdf --ocr-mode full_page
Export Lossless JSON

Export detailed DoclingDocument JSON schema containing bounding boxes.

docling document.pdf --to json
Enable Code & Formula Enrichment

Use specialized neural models to extract LaTeX formulas and code blocks.

docling paper.pdf --enrich-code --enrich-formula
Transcribe Audio & Video

Convert MP3 or WAV audio tracks into structured WebVTT or Markdown text.

docling lecture.mp3 --pipeline asr --to md
Pre-Download All AI Models

Download all layout and table models into local cache before offline use.

docling-tools models download --all
Run Docling MCP Server

Launch Model Context Protocol server for Claude Desktop integration.

uvx --from=docling-mcp docling-mcp-server

Integrations & Ecosystem Tools

Docling seamlessly integrates with leading frameworks and platforms.

Tool / Extension Category Open Source Best For
docling-serve FastAPI REST Server MIT Self-hosting an HTTP document conversion endpoint for microservices.
docling-mcp MCP Server MIT Connecting Docling directly to AI desktop apps like Claude and LM Studio.
LangChain (`langchain-docling`) RAG Framework MIT Loading parsed documents directly into LangChain vector stores.
LlamaIndex Reader Data Framework MIT Creating structured LlamaIndex document nodes from PDFs.
Apify Docling Actor Cloud Scraping Commercial / Free tier Automating cloud-scale web document extraction tasks.

CLI & Python Config Generator

Customize pipeline flags and generate executable CLI commands and Python SDK code in real-time.

Enable OCR Engine
Enrich Code Blocks
Enrich LaTeX Formulas
Extract Chart Data

CLI Command Output

docling bash command

              

Python SDK Equivalent

docling python script

              

Frequently Asked Questions

Answers to common queries regarding Docling installation, features, and troubleshooting.

What is Docling and what does it do?
Docling is an open-source document conversion and layout analysis engine created by IBM Research. It parses PDFs, Microsoft Office files (DOCX, PPTX, XLSX), HTML, EPUB, scanned images, and audio into structured Markdown and JSON formats optimized for AI models, Retrieval-Augmented Generation (RAG), and vector databases.
Is Docling completely free and open-source?
Yes, Docling is 100% open-source software released under the permissive MIT License. You can run Docling locally on your own infrastructure without paying cloud API subscription fees or sending data to external endpoints.
Does Docling support Python 3.13 and Python 3.14?
Docling fully supports Python 3.9 through Python 3.14. Python 3.13 is supported starting from Docling version 2.18.0+, while Python 3.14 is supported starting from Docling version 2.59.0+.
How do I fix PyTorch numpy version conflicts during installation?
When installing Docling alongside other packages like LangChain on Python 3.13, numpy version conflicts can occur. To resolve this, ensure you are using docling-ibm-models >= 2.0.7 or specify numpy compatibility ranges in your pyproject.toml (`numpy = [{ version = "^2.1.0", markers = 'python_version >= "3.13"' }]`).
How do I set up Tesseract OCR with Docling?
To use Tesseract with Docling, install the system Tesseract binaries (`brew install tesseract` on macOS or `apt-get install tesseract-ocr` on Linux), set your `TESSDATA_PREFIX` environment variable to the tessdata folder, and install the tesserocr extra via `pip install "docling[tesserocr]"`.
Can I use Docling with Claude Desktop via Model Context Protocol (MCP)?
Yes, Docling provides a dedicated MCP server package (`docling-mcp`). You can add it to your `claude_desktop_config.json` by specifying `{"mcpServers": {"docling": {"command": "uvx", "args": ["--from=docling-mcp", "docling-mcp-server"]}}}`.
How can I run Docling as a self-hosted HTTP REST API?
You can run Docling as an HTTP microservice using `docling-serve` (v1.21.0), a FastAPI server. Simply run the Docker container `ghcr.io/docling-project/docling-serve:latest` or install `docling-serve` via pip to expose endpoints like `/v1/convert/source/async`.
How do I chunk PDFs for RAG using Docling HybridChunker?
Docling includes native chunking algorithms like HybridChunker that operate directly on structural nodes. Unlike standard text splitters that break text blindly by character counts, Docling HybridChunker preserves section headings, table matrices, page numbers, and spatial bounding box metadata for vector stores like Qdrant, Milvus, and Pinecone.
How can I speed up Docling document conversion on GPU?
You can maximize Docling throughput on NVIDIA CUDA or Apple Silicon MPS by configuring AcceleratorOptions(device=AcceleratorDevice.CUDA) and setting ThreadedPdfPipelineOptions(page_batch_size=8, ocr_batch_size=64) to batch neural inference across multiple document pages simultaneously.
How do I integrate Docling with LangChain and LlamaIndex?
Docling provides native integration packages for popular RAG frameworks. You can use DoclingLoader from langchain-docling or DoclingReader from llama-index-readers-docling to load parsed PDF nodes directly into LangChain and LlamaIndex index pipelines.
Is Docling an OCR engine itself or how does it compare to Tesseract, PaddleOCR, and EasyOCR?
Docling is not a standalone raw OCR engine. Instead, Docling is a high-level document understanding framework that wraps and orchestrates pluggable OCR engines (including EasyOCR, Tesseract, RapidOCR/PaddleOCR, OcrMac, and Nemotron OCR). While raw OCR engines only extract text strings from cropped image pixels, Docling adds neural layout detection, multi-column reading order recovery, TableFormer matrix extraction, and exports structured Markdown and JSON for LLM RAG pipelines.
How does Docling compare to Unstructured.io?
Unlike Unstructured.io which relies heavily on cloud API tiers for advanced table processing, Docling offers the open-source TableFormer model natively for local execution. Docling also includes built-in audio transcription (Whisper) and direct MCP server integration out-of-the-box.