Docling Command Finder

Every common Docling task and the exact command to run. Search, filter, pin and copy — then read the full flag reference and the v1→v2 migration table below. Commands use the current docling convert syntax; verify against the official CLI reference.

Convert PDF to Markdown

BasicsStarter

Convert a local PDF into clean, structured Markdown.

docling convert report.pdf --to md
Flags, output & tips

Flags used

  • --to md Export Markdown (the default output format).

Expected output

# Annual Report

## Revenue

| Year | Revenue |
|------|--------:|
| 2025 | $12M |
| 2026 | $15M |

Variations

Skip OCR for a digital PDF (much faster)

docling convert report.pdf --to md --no-ocr

Write straight into a folder

docling convert report.pdf --to md --output ./out

Common mistake: Running on a scanned PDF and getting empty text. If the PDF has no text layer, add --ocr-mode full_page.

Official docs → · PDF to JSON · Save to a folder

Convert a document from a URL

BasicsStarter

Download and convert an online document directly from an HTTP(S) URL.

docling convert https://arxiv.org/pdf/2408.09869 --to md
Flags, output & tips

Flags used

  • --to md Markdown output.

Expected output

## Docling Technical Report

The conversion pipeline analyses layout, reading order and tables…

Variations

Send request headers (auth / token)

docling convert https://example.com/report.pdf --headers '{"Authorization":"Bearer TOKEN"}' --to md

Export JSON instead

docling convert https://arxiv.org/pdf/2408.09869 --to json

Common mistake: Assuming any URL works. The source must be a supported document format reachable over HTTP(S).

Official docs → · Supported formats

Export lossless JSON

BasicsStarter

Export the full DoclingDocument JSON schema, including bounding boxes and reading order.

docling convert report.pdf --to json
Flags, output & tips

Flags used

  • --to json Lossless JSON representation of the document tree.

Expected output

{
  "schema_name": "DoclingDocument",
  "texts": [ ... ],
  "tables": [ ... ],
  "pictures": [ ... ]
}

Variations

Skip OCR for speed

docling convert report.pdf --to json --no-ocr

Embed images as base64

docling convert report.pdf --to json --image-export-mode embedded

Common mistake: Expecting CLI JSON and export_to_dict() to be byte-identical; they are equivalent views of the same document.

Official docs → · PDF to Markdown · Export images as files

Check the installed version

BasicsStarter

Print the Docling, docling-core and docling-ibm-models versions.

docling --version
Flags, output & tips

Flags used

  • --version Shows Docling, docling-core and docling-ibm-models versions.

Expected output

Docling version: 2.129.0
Docling Core version: 2.x.x
Docling IBM Models version: 3.x.x
Python: cpython-312 …

Variations

Upgrade to the latest release

pip install -U docling docling-core docling-ibm-models

Common mistake: Reporting a bug without the version output — always include it, since flags change between releases.

Official docs → · Troubleshooting

Read the built-in help

BasicsStarter

List every flag the installed Docling version supports, straight from the CLI.

docling convert --help
Flags, output & tips

Expected output

Usage: docling convert [OPTIONS] SOURCE

  --from TEXT        Input formats to accept…
  --to TEXT          Output formats…
  --ocr-engine TEXT  The OCR engine to use…

Variations

List the top-level commands

docling --help

Inspect the remote converter

docling convert-remote --help

Common mistake: Trusting old blog posts. Always confirm flags with --help for your installed version.

Official docs → · Full flag reference

Save results to a folder

BasicsStarter

Write converted files into a specific output directory instead of the current one.

docling convert report.pdf --to md --output ./out
Flags, output & tips

Flags used

  • --output Directory where results are written (default: current directory).

Expected output

./out/report.md

Variations

Export several formats at once

docling convert report.pdf --to md --to json --to html --output ./out

Common mistake: Forgetting that --output takes a directory, not a file name. Combine it with --to to choose the extension.

Official docs → · Convert a whole folder · Multiple output formats

Export several formats at once

OutputIntermediate

The --to flag is repeatable: produce Markdown, JSON and HTML in a single run.

docling convert report.pdf --to md --to json --to html
Flags, output & tips

Flags used

  • --to Repeatable. Available: md, json, yaml, html, html_split_page, text, doctags, vtt, doclang, dclx, chunks, latex.

Expected output

report.md  report.json  report.html

Variations

Everything into one folder

docling convert report.pdf --to md --to json --output ./out

Common mistake: Passing a comma-separated list (--to md,json). Repeat the flag instead.

Official docs → · Output format reference

Convert an entire folder

BasicsIntermediate

Point Docling at a directory and it walks every supported document inside it.

docling convert ./inbox --output ./out
Flags, output & tips

Flags used

  • --output Folder for the converted results.
  • --abort-on-error Optional: stop at the first file that fails.

Expected output

Converting ./inbox/a.pdf … done
Converting ./inbox/b.docx … done

Variations

Keep going even if one file fails

docling convert ./inbox --output ./out --no-abort-on-error

Filter to one format

docling convert ./inbox --from pdf --output ./out

Common mistake: Expecting recursion into sub-folders to always be desired — check the printed file list before a big run.

Official docs → · Convert many explicit files · Batch recipes

Convert several named files

BasicsIntermediate

Pass multiple paths in one command; each is converted independently.

docling convert a.pdf b.docx c.pptx --output ./out
Flags, output & tips

Flags used

  • source Accepts one or more local paths, directories or URLs.

Expected output

a.md  b.md  c.md  written to ./out

Variations

Mixed sources including a URL

docling convert a.pdf https://example.com/b.pdf --output ./out

Common mistake: Quoting a glob ("*.pdf") and expecting the shell to expand it — let the shell expand it, or pass the directory.

Official docs → · Convert a whole folder

Pre-download all models

Offline & modelsIntermediate

Cache layout, table, OCR and enrichment models locally before first use or offline runs.

docling-tools models download --all
Flags, output & tips

Flags used

  • --all Download every available model (large).

Expected output

Downloading layout model…
Downloading tableformer model…
Models cached in $HOME/.cache/docling/models

Variations

Download only what you need

docling-tools models download layout tableformer rapidocr

Download a HuggingFace repo

docling-tools models download-hf-repo docling-project/docling-models

Common mistake: Downloading --all on a metered connection — pick the specific models you use.

Official docs → · Point at an artifacts path · Run fully offline

Convert DOCX to Markdown

FormatsStarter

Parse Microsoft Word documents, preserving headings, lists and tables.

docling convert contract.docx --to md
Flags, output & tips

Flags used

  • --to md Markdown output.

Expected output

# Service Agreement

1. Scope
2. Payment terms…

Variations

Legacy .doc files

docling convert contract.doc --to md

Common mistake: Expecting OCR options to matter — Office formats are parsed natively, so --ocr-engine has no effect.

Official docs → · All input formats

Convert PPTX to Markdown

FormatsStarter

Extract slide text boxes, titles and speaker notes from PowerPoint decks.

docling convert slides.pptx --to md
Flags, output & tips

Flags used

  • --page-range Optional: convert only e.g. the first slides (1-5).

Expected output

## Slide 1 — Overview

Bullet one
Bullet two

Variations

Only the first ten slides

docling convert slides.pptx --page-range 1-10 --to md

Common mistake: Assuming images inside slides are described — add --enrich-picture-description for that.

Official docs → · Enrich picture descriptions · Convert a page range

Convert XLSX to Markdown

FormatsStarter

Parse Excel workbooks sheet by sheet into structured tables.

docling convert workbook.xlsx --to md
Flags, output & tips

Flags used

  • --page-range Optional: limit which sheets are converted.

Expected output

## Sheet 1

| Region | Q1 | Q2 |
|--------|----|----|
| EMEA   | 12 | 15 |

Variations

Lossless structure

docling convert workbook.xlsx --to json

Common mistake: Treating XLSX like a PDF and enabling OCR — spreadsheets have no bitmap pages by default.

Official docs → · Output format reference

Convert HTML to Markdown

FormatsStarter

Parse saved HTML pages or local .html files into Markdown.

docling convert page.html --to md
Flags, output & tips

Flags used

  • --html-image-fetch Fetch images referenced by HTML/EPUB (none, local, remote, all).

Expected output

# Page title

Body text converted from HTML…

Variations

Download remote images too

docling convert page.html --html-image-fetch remote --to md

Common mistake: Forgetting image fetching is off by default; pass --html-image-fetch if you need the pictures.

Official docs → · Supported formats

Convert CSV to Markdown

FormatsStarter

Turn comma-separated data into a Markdown table.

docling convert data.csv --to md
Flags, output & tips

Flags used

  • --to md Markdown table output.

Expected output

| name | score |
|------|------:|
| Ada  | 98    |

Variations

Keep it as structured JSON

docling convert data.csv --to json

Common mistake: Using a delimiter other than a comma/standard CSV dialect — normalise it first.

Official docs → · Supported formats

Convert EPUB to Markdown

FormatsIntermediate

Convert e-books and long-form EPUB content while keeping chapter structure.

docling convert book.epub --to md
Flags, output & tips

Flags used

  • --html-image-fetch Fetch images embedded in the EPUB.

Expected output

# Chapter 1

Long-form text…

Variations

Include the illustrations

docling convert book.epub --html-image-fetch all --to md

Common mistake: Not fetching images and then wondering why figures are missing.

Official docs → · Supported formats

Convert Markdown to HTML

FormatsIntermediate

Reprocess a Markdown file and export clean HTML (tables and code preserved).

docling convert notes.md --to html
Flags, output & tips

Flags used

  • --to html HTML output.

Expected output

<h1>Notes</h1>
<p>…</p>

Variations

Split long pages

docling convert notes.md --to html_split_page

Common mistake: Expecting image files to be authored — HTML export references boxes, it does not render new images.

Official docs → · Output format reference

Convert LaTeX to Markdown

FormatsAdvanced

Parse LaTeX sources, with optional TikZ diagram rendering.

docling convert paper.tex --to md
Flags, output & tips

Flags used

  • --tikz-engine Set to 'tectonic' to rasterize tikzpicture diagrams.

Expected output

# Introduction

The math is preserved as LaTeX where possible…

Variations

Render TikZ diagrams to images

docling convert paper.tex --tikz-engine tectonic --to md

Common mistake: TikZ rendering silently falls back to keeping the source when Tectonic is missing or fails.

Official docs → · Supported formats

OCR a single image

OCRIntermediate

Convert a PNG/JPEG/TIFF image of text into Markdown using OCR.

docling convert scan.png --to md --ocr-mode full_page
Flags, output & tips

Flags used

  • --ocr-mode full_page OCR the whole image.
  • --ocr-engine Optionally pick a specific engine.

Expected output

Text recognised from the image…

Variations

Use RapidOCR

docling convert scan.png --ocr-engine rapidocr --to md

Common mistake: Using the default OCR mode on a low-DPI photo: increase resolution for better accuracy.

Official docs → · OCR a scanned PDF · Compare OCR engines

OCR a scanned PDF

OCRStarter

Force full-page OCR on image-only pages that have no selectable text.

docling convert scan.pdf --ocr-mode full_page --to md
Flags, output & tips

Flags used

  • --ocr-mode full_page OCR every page from its rendered image and replace detected text.

Expected output

Text reconstructed from the scanned page images…

Variations

Pick the engine at the same time

docling convert scan.pdf --ocr-mode full_page --ocr-engine rapidocr --to md

Common mistake: Leaving OCR on for digital PDFs wastes time. Only force it when the text layer is missing or wrong.

Official docs → · Disable OCR for digital PDFs · Legacy --force-ocr migration

Choose an OCR engine

OCRIntermediate

Run OCR with a specific engine instead of the automatic choice.

docling convert scan.pdf --ocr-engine rapidocr --to md
Flags, output & tips

Flags used

  • --ocr-engine auto, easyocr, rapidocr, tesserocr, tesseract, ocrmac, nemotron-ocr, kserve_v2_ocr.

Expected output

Using OCR engine: rapidocr

Variations

Tesseract with a language

docling convert scan.pdf --ocr-engine tesseract --ocr-lang eng --to md

Apple Vision on macOS

docling convert scan.pdf --ocr-engine ocrmac --to md

Common mistake: Choosing an engine that is not installed. RapidOCR is the safest cross-platform default.

Official docs → · Compare OCR engines · Multilingual OCR

OCR in a specific language

OCRIntermediate

Tell the OCR engine which language(s) to expect for much better accuracy.

docling convert scan.pdf --ocr-engine tesseract --ocr-lang deu,fra --to md
Flags, output & tips

Flags used

  • --ocr-lang Comma-separated native engine codes (e.g. deu,fra) or BCP-47 tags prefixed with iso: (e.g. iso:zh-Hans).

Expected output

Using OCR languages: deu, fra

Variations

Simplified Chinese via BCP-47

docling convert scan.pdf --ocr-engine rapidocr --ocr-lang iso:zh-Hans --to md

Let the engine auto-detect

docling convert scan.pdf --ocr-lang '' --to md

Common mistake: Mixing engine conventions. Each engine has its own codes — prefix canonical BCP-47 tags with iso:.

Official docs → · Compare OCR engines

Disable OCR (digital PDFs)

OCRStarter

Skip OCR entirely for PDFs that already contain a text layer — often several times faster.

docling convert report.pdf --no-ocr --to md
Flags, output & tips

Flags used

  • --no-ocr Turn OCR off; the embedded text layer is used as-is.

Expected output

Skipping OCR (digital text layer detected)…

Variations

Also skip tables you do not need

docling convert report.pdf --no-ocr --no-tables --to md

Common mistake: Using --no-ocr on a scan: you will get empty or near-empty output.

Official docs → · OCR a scanned PDF · Performance guide

OCR only layout regions

OCRAdvanced

Run OCR just on detected layout regions instead of the full page.

docling convert report.pdf --ocr-mode layout_regions --to md
Flags, output & tips

Flags used

  • --ocr-mode layout_regions Feed detected layout regions to the OCR engine.

Expected output

OCR applied to detected layout regions…

Variations

PDF-aware region selection

docling convert report.pdf --ocr-mode pdf_aware_layout_regions --to md

Common mistake: Using region modes when the whole page is one photo — use full_page there instead.

Official docs → · OCR a scanned PDF

Set the Tesseract page segmentation mode

OCRAdvanced

Fine-tune Tesseract layout analysis with a page segmentation mode (0-13).

docling convert scan.pdf --ocr-engine tesseract --psm 6 --to md
Flags, output & tips

Flags used

  • --psm Page Segmentation Mode (0-13). Applies to Tesseract engines.

Expected output

Tesseract PSM 6 — assume a single uniform block of text.

Variations

Single line of text

docling convert scan.pdf --ocr-engine tesseract --psm 7 --to md

Common mistake: Setting PSM for non-Tesseract engines where it is ignored.

Official docs → · Choose an OCR engine

Faster table extraction

TablesIntermediate

Use the fast table mode instead of the accurate model when speed matters.

docling convert report.pdf --table-mode fast --to md
Flags, output & tips

Flags used

  • --table-mode accurate (TableFormer, default) or fast.

Expected output

Rough table grid, produced faster…

Variations

Skip tables entirely

docling convert report.pdf --no-tables --to md

Common mistake: Using fast on financial sheets with merged cells — accuracy drops noticeably.

Official docs → · Disable tables

Disable table extraction

TablesIntermediate

Skip the table structure model when you only need prose text.

docling convert report.pdf --no-tables --to md
Flags, output & tips

Flags used

  • --no-tables Do not run the table structure model.

Expected output

Tables rendered as plain text flow…

Variations

Fastest digital text path

docling convert report.pdf --no-ocr --no-tables --to md

Common mistake: Enabling it when tables matter — table content will collapse into paragraphs.

Official docs → · Faster table extraction

Use the TableFormer v2 engine

TablesAdvanced

Select a specific table structure engine, including newer TableFormer v2.

docling convert report.pdf --table-structure-engine docling_tableformer_v2 --to md
Flags, output & tips

Flags used

  • --table-structure-engine docling_tableformer (default), docling_tableformer_v2, granite_vision_table.

Expected output

Using table structure engine: docling_tableformer_v2

Variations

Granite vision table engine

docling convert report.pdf --table-structure-engine granite_vision_table --to md

Common mistake: Assuming every engine is bundled — some require extra model downloads or plugins.

Official docs → · Faster table extraction

Enable code and formula enrichment

EnrichmentIntermediate

Detect code blocks and extract LaTeX formulas with enrichment models.

docling convert paper.pdf --enrich-code --enrich-formula --to md
Flags, output & tips

Flags used

  • --enrich-code Detect and label code blocks.
  • --enrich-formula Extract formulas as LaTeX.

Expected output

```python
def hello(): …
```

$$ E = mc^2 $$

Variations

Only formulas

docling convert paper.pdf --enrich-formula --to md

Only code

docling convert repo.pdf --enrich-code --to md

Common mistake: Enabling both on documents without code or math — each adds a neural pass and slows conversion.

Official docs → · Enrich picture descriptions · Extract chart data

Describe pictures with a VLM

EnrichmentAdvanced

Generate natural-language descriptions for figures and images.

docling convert report.pdf --enrich-picture-description --to md
Flags, output & tips

Flags used

  • --enrich-picture-description Run a picture-description model over detected pictures.

Expected output

<!-- picture: a bar chart showing revenue growth from 2020 to 2026 -->

Variations

Cap generated tokens

docling convert report.pdf --enrich-picture-description --picture-description-max-new-tokens 256 --to md

Common mistake: Running it on image-heavy documents without enough RAM/VRAM — it loads a vision model.

Official docs → · Classify pictures

Classify pictures

EnrichmentAdvanced

Label pictures by class (chart, diagram, screenshot, photo…) with a classifier model.

docling convert report.pdf --enrich-picture-classes --to md
Flags, output & tips

Flags used

  • --enrich-picture-classes Run the picture classification model.

Expected output

<!-- picture class: chart -->

Variations

Classify and describe

docling convert report.pdf --enrich-picture-classes --enrich-picture-description --to md

Common mistake: Expecting pixel-perfect labels — it is a lightweight classifier, not a full vision model.

Official docs → · Describe pictures

Extract chart data to tables

EnrichmentAdvanced

Turn bar, pie and line charts into tabular data using the chart-extraction model.

docling convert report.pdf --enrich-chart-extraction --to md
Flags, output & tips

Flags used

  • --enrich-chart-extraction Extract chart data from bar, pie and line charts.

Expected output

<!-- chart: category | value -->
<!-- 2025 | 12 -->

Variations

Combine with table output

docling convert report.pdf --enrich-chart-extraction --to json

Common mistake: Expecting scans of complex 3D charts to be extracted — graphs beyond bar/pie/line are out of scope.

Official docs → · Enrich code and formula

Chunk for RAG (hybrid)

RAGIntermediate

Export HybridChunker chunks that preserve headings, tables and metadata for vector stores.

docling convert report.pdf --to chunks --chunks-type hybrid
Flags, output & tips

Flags used

  • --to chunks Export RAG-ready chunks.
  • --chunks-type hybrid (default) or hierarchical.

Expected output

{ "text": "…", "meta": { "headings": ["Revenue"] } }

Variations

Cap chunk size

docling convert report.pdf --to chunks --chunks-max-tokens 512

Hierarchical chunks

docling convert report.pdf --to chunks --chunks-type hierarchical

Common mistake: Chunking the Markdown export with a naive splitter instead of using Docling's structure-aware chunker.

Official docs → · RAG guide · Chunks max tokens

Set the chunk size

RAGAdvanced

Control the maximum tokens per chunk and the tokenizer used for hybrid chunking.

docling convert report.pdf --to chunks --chunks-max-tokens 512
Flags, output & tips

Flags used

  • --chunks-max-tokens Max tokens per chunk (defaults to the tokenizer's limit).
  • --chunks-tokenizer HuggingFace tokenizer (default sentence-transformers/all-MiniLM-L6-v2).

Expected output

Chunks sized to the embedding model's token limit…

Variations

Match another embedding model

docling convert report.pdf --to chunks --chunks-tokenizer BAAI/bge-small-en-v1.5

Common mistake: Setting a chunk size larger than your embedding model supports — it will be truncated.

Official docs → · Chunk for RAG

Convert with the Granite VLM

VLMAdvanced

Use the vision-language pipeline with IBM's Granite Docling model for complex layouts.

docling convert report.pdf --pipeline vlm --vlm-model granite_docling --to md
Flags, output & tips

Flags used

  • --pipeline vlm Select the VLM pipeline.
  • --vlm-model Preset: granite_docling (default), smoldocling, deepseek_ocr, granite_vision, and more.

Expected output

Markdown generated page-by-page by the vision model…

Variations

Smaller SmolDocling preset

docling convert report.pdf --pipeline vlm --vlm-model smoldocling --to md

Keep the raw model output

docling convert report.pdf --pipeline vlm --vlm-write-native-output

Common mistake: Assuming VLM is always better — for plain digital PDFs the standard pipeline is faster and cheaper.

Official docs → · Vision model guide · Standard PDF to Markdown

Cap VLM generation length

VLMAdvanced

Override the maximum number of tokens the VLM may generate per page.

docling convert report.pdf --pipeline vlm --vlm-max-new-tokens 8192 --to md
Flags, output & tips

Flags used

  • --vlm-max-new-tokens Override max_new_tokens for VLM generation.

Expected output

Long, dense pages no longer get cut off…

Variations

Keep raw output for debugging

docling convert report.pdf --pipeline vlm --vlm-write-native-output

Common mistake: Leaving the default on very dense pages can truncate the page output.

Official docs → · Convert with the Granite VLM

Transcribe audio (ASR)

Audio & VideoIntermediate

Transcribe WAV/MP3 audio into Markdown with the ASR pipeline.

docling convert lecture.mp3 --pipeline asr --to md
Flags, output & tips

Flags used

  • --pipeline asr Select the speech-recognition pipeline.
  • --asr-model Whisper size: whisper_tiny (default) … whisper_large.

Expected output

00:00:00 — Welcome to the show…

Variations

Better accuracy

docling convert lecture.mp3 --pipeline asr --asr-model whisper_medium --to md

Subtitles output

docling convert lecture.mp3 --pipeline asr --to vtt

Common mistake: Using the default whisper_tiny for an important transcript; pick medium/large for accuracy.

Official docs → · Transcribe video · Audio & video guide

Transcribe video to subtitles

Audio & VideoIntermediate

Transcribe a video's audio and export WebVTT subtitles with timestamps.

docling convert talk.mp4 --pipeline asr --to vtt
Flags, output & tips

Flags used

  • --to vtt WebVTT subtitle output with timestamps.

Expected output

WEBVTT

00:00:00.000 --> 00:00:04.000
Hello and welcome…

Variations

Different ASR model

docling convert talk.mp4 --pipeline asr --asr-model whisper_small --to vtt

Common mistake: Expecting OCR/table flags to apply — video uses the ASR pipeline only.

Official docs → · Transcribe audio

Sample video by scene changes

Audio & VideoAdvanced

Choose how frames are sampled from video: a fixed interval or scene changes.

docling convert talk.mp4 --pipeline asr --video-sampling-mode scene
Flags, output & tips

Flags used

  • --video-sampling-mode fixed (default) or scene.
  • --video-frame-interval Seconds between frames in fixed mode (default 10).

Expected output

Frames sampled at scene changes…

Variations

Denser fixed sampling

docling convert talk.mp4 --pipeline asr --video-frame-interval 5

Common mistake: Using scene mode on a single static camera — fixed interval is more predictable there.

Official docs → · Transcribe video

Speaker diarization (who said what)

Audio & VideoAdvanced

Label speakers in audio/video transcripts (requires the resemblyzer extra).

docling convert interview.mp4 --pipeline asr --video-diarization
Flags, output & tips

Flags used

  • --video-diarization Enable speaker diarization; requires resemblyzer.

Expected output

[SPEAKER_00] …
[SPEAKER_01] …

Variations

Disable diarization explicitly

docling convert interview.mp4 --pipeline asr --no-video-diarization

Common mistake: Forgetting that diarization needs the resemblyzer dependency installed.

Official docs → · Transcribe audio

Export images as PNG files

OutputIntermediate

Write figures out as separate PNG files and reference them from the output document.

docling convert report.pdf --to md --image-export-mode referenced --output ./out
Flags, output & tips

Flags used

  • --image-export-mode embedded (base64, default), placeholder, or referenced (PNG files).

Expected output

./out/report.md + ./out/report_artifacts/*.png

Variations

Only mark image positions

docling convert report.pdf --to md --image-export-mode placeholder

Embed as base64

docling convert report.pdf --to json --image-export-mode embedded

Common mistake: Using referenced with --to json and expecting the PNGs next to it — check the artifacts folder.

Official docs → · Lossless JSON

Export DocTags

OutputAdvanced

Produce compact token-style DocTags markup used as model input.

docling convert report.pdf --to doctags
Flags, output & tips

Flags used

  • --to doctags DocTags markup output.

Expected output

<doctag><page_1><section_header_level_1>Annual Report</section_header_level_1>…

Variations

With VLM-native output

docling convert report.pdf --pipeline vlm --to doctags

Common mistake: Treating DocTags like Markdown — it is a compact internal representation for models.

Official docs → · Output format reference

Export paginated HTML

OutputAdvanced

Produce HTML split per page — handy for viewers and side-by-side review.

docling convert report.pdf --to html_split_page --output ./out
Flags, output & tips

Flags used

  • --to html_split_page One HTML file per page.

Expected output

./out/report_1.html  report_2.html …

Variations

Single-file HTML

docling convert report.pdf --to html

Common mistake: Looking for a single HTML file when split output writes one per page.

Official docs → · Output format reference

Visualise detected layout

OutputAdvanced

Overlay detected item bounding boxes on page images in the output.

docling convert report.pdf --show-layout --to md --output ./out
Flags, output & tips

Flags used

  • --show-layout Show item bounding boxes on page images.

Expected output

Page images with coloured layout boxes…

Variations

Visualise table cells

docling convert report.pdf --debug-visualize-tables

Common mistake: Expecting boxes drawn on the Markdown itself — they are drawn on exported page images.

Official docs → · Debug visualisers

Run on an NVIDIA GPU (CUDA)

PerformanceIntermediate

Accelerate inference with CUDA and tune thread/batch settings.

docling convert report.pdf --device cuda --num-threads 8 --to md
Flags, output & tips

Flags used

  • --device cuda Use the NVIDIA GPU.
  • --num-threads CPUs used for model inference (default 4).

Expected output

Using accelerator device: cuda

Variations

Larger page batches

docling convert big.pdf --device cuda --page-batch-size 16

Common mistake: Passing --device cuda on a machine with no CUDA runtime; use auto or cpu instead.

Official docs → · Apple Silicon (MPS) · GPU troubleshooting

Run on Apple Silicon (MPS)

PerformanceIntermediate

Use the Metal backend on M-series Macs for accelerated inference.

docling convert report.pdf --device mps --to md
Flags, output & tips

Flags used

  • --device mps Use Apple Metal Performance Shaders.

Expected output

Using accelerator device: mps

Variations

Let Docling choose

docling convert report.pdf --device auto --to md

Common mistake: Expecting MPS to match a discrete GPU — it is a solid speed-up, not a data-centre card.

Official docs → · Run on CUDA

Increase the page batch size

PerformanceAdvanced

Process more pages per batch to raise GPU/CPU throughput on large documents.

docling convert big.pdf --page-batch-size 16 --to md
Flags, output & tips

Flags used

  • --page-batch-size Pages processed in one batch (default 4).

Expected output

Processing 16 pages per batch…

Variations

Back off if you run out of memory

docling convert big.pdf --page-batch-size 2

Common mistake: Raising it until you hit an out-of-memory error — lower it if conversion crashes.

Official docs → · Run on CUDA

Set a per-document timeout

PerformanceAdvanced

Protect a batch from a single pathological file by capping processing time.

docling convert ./inbox --document-timeout 120 --output ./out
Flags, output & tips

Flags used

  • --document-timeout Timeout per document, in seconds.

Expected output

Timed out after 120s — moving to the next file…

Variations

Abort the whole batch on failure

docling convert ./inbox --abort-on-error --output ./out

Common mistake: Setting a very short timeout on huge documents and getting false failures.

Official docs → · Convert a whole folder

Profile the conversion pipeline

PerformanceAdvanced

Summarise where time is spent across conversion stages to find bottlenecks.

docling convert report.pdf --profiling --to md
Flags, output & tips

Flags used

  • --profiling Summarise profiling details for all stages.
  • --save-profiling Save profiling summaries to JSON.

Expected output

layout: 3.2s  ocr: 1.1s  tableformer: 0.9s  total: 5.4s

Variations

Save the numbers to JSON

docling convert report.pdf --profiling --save-profiling

Common mistake: Profiling with -v left on and mistaking logging time for model time.

Official docs → · Performance guide

Convert only a page range

FormatsIntermediate

Parse a subset of pages instead of the whole document.

docling convert report.pdf --page-range 1-4 --to md
Flags, output & tips

Flags used

  • --page-range e.g. 1-4 (page numbers start at 1). Honoured by PDF, XLSX and PPTX.

Expected output

Converting pages 1-4 only…

Variations

Single page

docling convert report.pdf --page-range 3 --to md

Common mistake: Expecting all backends to honour the range — mainly PDF, XLSX and PPTX.

Official docs → · Password-protected PDFs

Open a password-protected PDF

FormatsAdvanced

Supply a password so encrypted PDFs can be converted.

docling convert locked.pdf --pdf-password 'secret' --to md
Flags, output & tips

Flags used

  • --pdf-password Password for protected PDF documents.

Expected output

Decrypting and converting locked.pdf…

Variations

Use a password from an environment variable

docling convert locked.pdf --pdf-password "$PDF_PW" --to md

Common mistake: Putting a real password in shell history; prefer an environment variable.

Official docs → · Convert a page range

Switch the PDF backend

FormatsAdvanced

Choose between the default docling-parse backend and pypdfium2 for problem PDFs.

docling convert report.pdf --pdf-backend pypdfium2 --to md
Flags, output & tips

Flags used

  • --pdf-backend docling_parse (default) or pypdfium2.

Expected output

Using PDF backend: pypdfium2

Variations

Default parser

docling convert report.pdf --pdf-backend docling_parse --to md

Common mistake: Sticking with the default on PDFs with broken font encodings — try pypdfium2.

Official docs → · Troubleshooting

Use a custom models path

Offline & modelsAdvanced

Point Docling at a pre-populated model directory instead of the default cache.

docling convert report.pdf --artifacts-path /opt/docling/models --to md
Flags, output & tips

Flags used

  • --artifacts-path Location of pre-downloaded model artifacts.

Expected output

Loading models from /opt/docling/models…

Variations

Use an environment variable instead

DOCLING_ARTIFACTS_PATH=/opt/docling/models docling convert report.pdf --to md

Common mistake: Pointing at an empty directory: Docling then tries to download and may fail offline.

Official docs → · Pre-download models · Run fully offline

Run fully offline (air-gapped)

Offline & modelsAdvanced

Prefetch models on a connected host, then convert with no network access.

export HF_HUB_OFFLINE=1; export DOCLING_ARTIFACTS_PATH=/opt/docling/models; docling convert report.pdf --to md
Flags, output & tips

Flags used

  • DOCLING_ARTIFACTS_PATH Directory holding the pre-downloaded models.
  • HF_HUB_OFFLINE Stop HuggingFace downloads and use the local cache only.

Expected output

Conversion completes with no outbound requests…

Variations

Choose the HF cache directory

export HF_HOME=/opt/docling/hf; docling convert report.pdf --to md

Common mistake: Forgetting HF_HUB_OFFLINE=1, which makes Docling attempt a network fetch and stall or fail.

Official docs → · Pre-download models

Run the Docling Serve API

ServeIntermediate

Start the docling-serve HTTP API and interactive UI on port 5001.

docling-serve run --enable-ui
Flags, output & tips

Flags used

  • --enable-ui Serve the built-in web UI alongside the API.

Expected output

Uvicorn running on http://0.0.0.0:5001  (docs at /docs)

Variations

Run in Docker

docker run -p 5001:5001 -e DOCLING_SERVE_ENABLE_UI=1 quay.io/docling-project/docling-serve

Common mistake: Exposing the service publicly without authentication — front it with a proxy and auth.

Official docs → · Convert via a remote service · docling-serve docs

Convert through a remote service

ServeAdvanced

Offload conversion to a running docling-serve instance (local files, folders or URLs).

docling convert-remote report.pdf --service-url http://localhost:5001 --to md
Flags, output & tips

Flags used

  • --service-url Base URL of docling-serve (or DOCLING_SERVICE_URL).
  • --api-key Optional API key (or DOCLING_SERVICE_API_KEY).

Expected output

submitting job… polling… report.md written

Variations

Authenticated service

docling convert-remote report.pdf --service-url https://docling.internal --api-key "$DOCLING_KEY" --to md

Use polling instead of websocket

docling convert-remote report.pdf --service-url http://localhost:5001 --watcher polling --to md

Common mistake: Passing local-only flags like --device to convert-remote; they are intentionally absent.

Official docs → · Run the Docling Serve API

Run the MCP server

MCPIntermediate

Expose Docling to AI desktop clients (Claude Desktop, LM Studio) over the Model Context Protocol.

uvx --from=docling-mcp docling-mcp-server
Flags, output & tips

Flags used

  • --from=docling-mcp Runs the MCP server package without a global install.

Expected output

docling-mcp server ready (stdio)

Variations

JSON config for an AI client

{"mcpServers": {"docling": {"command": "uvx", "args": ["--from=docling-mcp", "docling-mcp-server"]}}}

Common mistake: Pasting the command instead of the JSON block into the client's MCP configuration.

Official docs → · MCP guide

Increase log verbosity

DebugIntermediate

Print progress (-v) or full debug logging (-vv) to diagnose a conversion.

docling convert report.pdf -vv --to md
Flags, output & tips

Flags used

  • -v / --verbose Repeat for more detail: -v info, -vv debug.
  • -q / --quiet Silence per-file progress (warnings and errors remain).

Expected output

DEBUG docling.pipeline… loading layout model

Variations

Silent batch for scripting

docling convert ./inbox --quiet --output ./out

Common mistake: Leaving -vv on in production — debug logging is slow and very noisy.

Official docs → · Debug visualisers

Visualise cells, OCR and tables

DebugAdvanced

Debug visualisers render what each stage detected, for tuning and troubleshooting.

docling convert report.pdf --debug-visualize-tables
Flags, output & tips

Flags used

  • --debug-visualize-layout Visualise layout clusters.
  • --debug-visualize-tables Visualise table cells.
  • --debug-visualize-ocr Visualise OCR cells.
  • --debug-visualize-cells Visualise PDF cells.

Expected output

Annotated page images written next to the output…

Variations

Inspect OCR detection

docling convert scan.pdf --debug-visualize-ocr

Inspect layout clusters

docling convert report.pdf --debug-visualize-layout

Common mistake: Using several visualisers at once and getting an overwhelming number of images.

Official docs → · Increase log verbosity

Pick your scenario

The fastest route from a document type to a working command. Copy one and change the file name.

Scanned PDF, no text layer

Full-page OCR recovers the content.

docling convert scan.pdf --ocr-mode full_page --to md

Digital PDF, fastest result

Skip OCR and tables you do not need.

docling convert report.pdf --no-ocr --to md

Research paper with math

Extract LaTeX formulas and code blocks.

docling convert paper.pdf --enrich-formula --enrich-code --to md

Financial report with tables

Keep accurate tables and lossless structure.

docling convert report.pdf --table-mode accurate --to json

Feed a RAG pipeline

Structure-aware chunks ready for embedding.

docling convert report.pdf --to chunks --chunks-type hybrid

Multilingual scan

Tell OCR which languages to expect.

docling convert scan.pdf --ocr-engine tesseract --ocr-lang deu,fra --to md

Transcribe a meeting

Speech to text with a larger Whisper model.

docling convert meeting.mp3 --pipeline asr --asr-model whisper_medium --to md

Complex visual layout

Let a vision-language model read the page.

docling convert brochure.pdf --pipeline vlm --vlm-model granite_docling --to md

Offline / air-gapped run

Use prefetched models with no network.

HF_HUB_OFFLINE=1 docling convert report.pdf --artifacts-path /opt/models --to md

Using the Docling CLI

How the command surface fits together — pipelines, OCR, output formats, performance, batch automation and the move from v1 syntax.

1
Start here

How the CLI works

In Docling v2, conversion lives under the explicit convert subcommand. The shape of every command is the same:

docling convert <source> [options]
  • source can be a local file, a directory, or an HTTP(S) URL.
  • Outputs are written next to you by default — choose a folder with --output and a format with --to.
  • Help is authoritative. docling convert --help always lists exactly what your installed version supports.
docling convert report.pdf --to md --output ./out
!Most older tutorials write docling report.pdf — that is v1 syntax and will not work today. See Migrate from v1.
iCompanion commands: docling-tools models prefetches models, docling convert-remote talks to a running service, and docling-serve exposes an HTTP API.
2
Pipeline

Choose a pipeline

The pipeline is the biggest structural choice: it decides which models run over your PDF or image.

PipelineUse it whenTrade-off
standardDefault for PDF and images — layout, OCR, tables.Balanced and well understood.
nativeYou want the threaded native parser for large PDFs.Fast parsing; tune with --parser-threads.
vlmComplex, visually rich layouts a single model handles better.Loads a vision model; slower and heavier.
asrAudio and video files (Whisper-family models).Speech only; OCR/table flags do not apply.
legacyReproducing older behaviour.Not recommended for new work.
docling convert report.pdf --pipeline vlm --vlm-model granite_docling --to md
iFor ordinary digital PDFs the standard pipeline is faster and cheaper than a VLM — start there.
3
Formats

Inputs and outputs

Docling reads PDF, the Office family, HTML, EPUB, CSV, images, audio/video and more. See the supported formats reference for the full list and per-format notes.

The --to flag is repeatable, so one run can emit several formats. Common outputs:

FormatWhat you getBest for
mdReadable Markdown with tablesNotes, docs, RAG text (default)
jsonLossless DoclingDocument with bounding boxesCustom pipelines and structure
chunksStructure-aware chunksEmbeddings and vector stores
htmlSingle HTML fileWeb previews and email
html_split_pageOne HTML file per pagePage-by-page viewers
doctagsCompact token-style markupModel input and token workflows
yaml, text, vtt, doclang, dclx, latexSerialised, subtitle, archive and source formatsSpecific downstream tools
docling convert report.pdf --to md --to json --to chunks --output ./out
iControl how pictures are handled with --image-export-mode placeholder|embedded|referenced.
4
OCR

Decide on OCR

OCR is the single biggest factor in both accuracy and runtime. Enable it deliberately.

  • Enable OCR for scans, photos and PDFs without a text layer.
  • Disable OCR for digital PDFs (--no-ocr) — often several times faster.
  • default mode only OCRs pages that are missing text; full_page OCRs every page and overwrites detected text.
  • layout_regions and pdf_aware_layout_regions OCR just the detected regions.
docling convert scan.pdf --ocr-mode full_page --to md
!Empty output from a scanned PDF? Force --ocr-mode full_page. OCR will not run on programmatic text even if the font is broken.

Pick an engine with --ocr-engine and give it a language with --ocr-lang. Compare engines on the OCR reference.

5
Performance

Speed and hardware

Conversion cost is dominated by which models run and where they run.

LeverEffect
--no-ocrBiggest win on digital PDFs.
--no-tables, skip enrichmentAvoids neural passes you do not need.
--device cuda|mps|xpuMoves inference to a GPU (CUDA, Apple Silicon, Intel).
--num-threadsCPU parallelism for model inference (default 4).
--page-batch-sizeMore pages per batch — raise until memory is tight.
--profilingShows time per stage so you optimise the real bottleneck.
docling convert report.pdf --device cuda --num-threads 8 --to md
iProtect long batches with --document-timeout 120. For air-gapped accelerators see --artifacts-path.
6
Automation

Batch & automation

Pass a directory and Docling walks it for you, or loop in your shell for full control over naming, parallelism and incremental runs.

Built-in folder conversionbash

Docling walks a directory for you — the simplest batch path.

docling convert ./inbox --output ./out
PowerShell folder looppowershell

Full control over which files are picked up on Windows.

Get-ChildItem ./inbox -Recurse -Filter *.pdf | ForEach-Object { docling convert $_.FullName --to md --output ./out }
Parallel batch with xargsbash

Four conversions at a time for a big backfill (mind CPU/RAM).

find ./inbox -name '*.pdf' -print0 \ | xargs -0 -P 4 -I{} docling convert {} --to md --output ./out
Only convert new filesbash

Skip files that already have an output, useful for incremental runs.

for f in ./inbox/*.pdf; do out="./out/$(basename "${f%.pdf}").md" [ -f "$out" ] || docling convert "$f" --to md --output ./out done
Robust production batchbash

Timeout per document and continue past failures.

docling convert ./inbox --output ./out \ --document-timeout 120 \ --no-abort-on-error \ --quiet
One format, streamedpowershell

Pipe a single document straight to a file on Windows.

docling convert .\report.pdf --to md | Out-File -Encoding utf8 .\report.md
!Parallel runs share one model pipeline per process — watch CPU and RAM, and lower -P or --page-batch-size if the machine swaps.
7
RAG

Chunks for RAG

Docling chunks the document tree, not a flat string, so headings and tables survive into the chunks.

docling convert report.pdf --to chunks --chunks-type hybrid --chunks-max-tokens 512
  • --chunks-type hybrid (default) or hierarchical.
  • --chunks-max-tokens matches your embedding model's limit.
  • --chunks-tokenizer chooses the HuggingFace tokenizer used to count tokens.

See the RAG guide for vector-store examples.

8
Offline

Offline & models

Prefetch models once on a connected host, then convert with no network on the isolated one.

docling-tools models download --all
HF_HUB_OFFLINE=1 docling convert report.pdf --artifacts-path /opt/docling/models --to md
  • docling-tools models download layout tableformer rapidocr fetches only what you use.
  • Set DOCLING_ARTIFACTS_PATH instead of the flag for scripts.
  • RapidOCR can struggle on read-only filesystems — prefer Tesseract in those environments.
9
Serving

Serve & remote conversions

Run conversion as a service when many clients or languages need it, then offload with the remote client.

docling-serve run --enable-ui
docling convert-remote report.pdf --service-url http://localhost:5001 --to md
iconvert-remote intentionally omits local-only flags such as --device — the server owns execution. For AI clients, see the MCP server guide.
10
Debug

Debug a conversion

When output looks wrong, increase logging first, then visualise what each stage detected.

docling convert report.pdf -vv --to md
  • -v info logging, -vv full debug logging, -q quiet for scripting.
  • --debug-visualize-layout, --debug-visualize-tables, --debug-visualize-ocr render what each stage found.
  • --show-layout overlays bounding boxes on exported page images.
  • --pdf-backend pypdfium2 helps with PDFs that use broken font encodings.
11
Migration

Migrate from v1 syntax

Docling v2 reorganised the command surface. If a tutorial, script or CI job uses the old form, map it with this table.

Old syntaxCurrent syntaxWhy
docling report.pdfdocling convert report.pdf --to mdv1 converted directly; v2 moved conversion under the convert subcommand.
docling report.pdf --format jsondocling convert report.pdf --to json--format became --to.
docling report.pdf -o out.mddocling convert report.pdf --to md --output ./out-o/--output is now a directory, not a destination file.
--force-ocr--ocr-mode full_page--force-ocr is deprecated; use the explicit OCR mode.
--ocr-engine tesseract_cli--ocr-engine tesseractEngine values were renamed; tesserocr is still valid for the C-binding engine.
--table-mode fast (no engine choice)--table-mode fast --table-structure-engine docling_tableformer_v2You can now pick the speed/accuracy mode and the underlying table engine separately.
docling --pipeline vlm doc.pdfdocling convert doc.pdf --pipeline vlm --vlm-model granite_doclingPipeline and model selection moved under convert.
docling-tools models downloaddocling-tools models download --allStill available; --all prefetches every model while bare names fetch a specific set.
!Note the --output change: it now names a directory, not a destination file. Use --to to choose the extension.
12
Fixes

Common problems at a glance

SymptomMost likely cause & fix
Empty or near-empty Markdown from a scanNo text layer — add --ocr-mode full_page.
Conversion is very slowOCR on a digital PDF — add --no-ocr; otherwise use a GPU (--device).
Garbled characters / GLYPH placeholdersBroken font encoding — try --pdf-backend pypdfium2.
Wrong OCR languageSet --ocr-lang using the engine's codes.
GPU not usedInstall a CUDA/MPS build of PyTorch and pass --device cuda|mps.
MCP client cannot connectUse the exact JSON block, not the raw command.

Full walkthroughs live in Troubleshooting.

Full CLI flag reference

Every flag worth knowing, with accepted values, defaults and what it does. Search it like the finder above.

FlagAccepted valuesDefaultWhat it does
--from repeatable text all supported Restrict which input formats are accepted. Use 'odf' for odt, ods and odp.
--to md, json, yaml, html, html_split_page, text, doctags, vtt, doclang, dclx, chunks, latex md Output format. Repeat the flag to export several formats at once.
--output path . Directory where results are saved (not a file name).
--image-export-mode placeholder, embedded, referenced embedded How images are exported for JSON, YAML, HTML and Markdown outputs.
--html-image-fetch none, local, remote, all none Fetch images referenced by HTML and EPUB inputs.
--page-range text (e.g. 1-4) all pages Convert only a range of pages. Honoured by PDF, XLSX and PPTX.
--pdf-password text - Password for protected PDF documents.
--pipeline legacy, standard, native, vlm, asr standard Processing pipeline for PDF and image files.
--vlm-model granite_docling, smoldocling, deepseek_ocr, granite_vision, pixtral, … granite_docling VLM preset used with --pipeline vlm.
--vlm-max-new-tokens integer model default Override max_new_tokens for VLM generation.
--vlm-write-native-output flag false Write each page's unparsed VLM response under <output>/<doc>.vlm-native/.
--asr-model whisper_tiny … whisper_large, plus _mlx and _native variants whisper_tiny ASR model for audio and video files.
--video-sampling-mode fixed, scene fixed How video frames are sampled.
--video-frame-interval float (seconds) 10.0 Seconds between frames in fixed interval mode.
--video-diarization flag false Enable speaker diarization (requires resemblyzer).
--ocr / --no-ocr flag true Enable or disable OCR on bitmap content.
--ocr-mode full_page, layout_regions, pdf_aware_layout_regions, default default Which document regions are fed to the OCR engine.
--ocr-engine auto, easyocr, rapidocr, tesserocr, tesseract, ocrmac, nemotron-ocr, kserve_v2_ocr auto OCR engine provider.
--ocr-lang comma-separated codes engine default OCR languages; use native engine codes or BCP-47 tags prefixed with iso:.
--psm integer 0-13 engine default Page Segmentation Mode for Tesseract engines.
--tables / --no-tables flag true Enable or disable the table structure model.
--table-mode accurate, fast accurate Accuracy/speed trade-off for the table structure model.
--table-structure-engine docling_tableformer, docling_tableformer_v2, granite_vision_table docling_tableformer Select the table structure engine.
--layout-engine layout_object_detection, docling_layout_default, … layout_object_detection Select the layout detection engine.
--enrich-code flag false Detect and label code blocks.
--enrich-formula flag false Extract formulas as LaTeX.
--enrich-picture-classes flag false Classify pictures (chart, diagram, screenshot…).
--enrich-picture-description flag false Generate descriptions for pictures with a vision model.
--enrich-chart-extraction flag false Extract data from bar, pie and line charts.
--chunks-type hybrid, hierarchical hybrid Chunker type used with --to chunks.
--chunks-max-tokens integer tokenizer limit Maximum tokens per chunk.
--chunks-tokenizer HuggingFace model id sentence-transformers/all-MiniLM-L6-v2 Tokenizer used for hybrid chunking.
--device auto, cpu, cuda, mps, xpu auto Hardware accelerator for model inference.
--num-threads integer 4 Threads used for model inference.
--page-batch-size integer 4 Pages processed in one batch.
--document-timeout float (seconds) none Timeout for processing each document.
--abort-on-error flag false Stop the whole run when the first file fails.
--profiling flag false Summarise time spent in each conversion stage.
--artifacts-path path HF cache Location of pre-downloaded model artifacts.
--enable-remote-services flag false Required when a model connects to a remote service.
--allow-external-plugins flag false Enable loading third-party plugin engines.
-v / --verbose repeatable 0 -v for info logs, -vv for debug logs.
-q / --quiet flag false Suppress per-file progress logs.
--show-layout flag false Overlay item bounding boxes on page images.
--debug-visualize-layout flag false Visualise layout clusters.
--debug-visualize-tables flag false Visualise table cells.
--debug-visualize-ocr flag false Visualise OCR cells.
--version flag - Show the installed Docling version.

Docling CLI questions

The questions that come up most often, answered with the command that solves them.

What is the difference between docling and docling convert?
In Docling v1 you could run docling file.pdf directly. In v2 conversion lives under the explicit docling convert subcommand. Old tutorials that omit convert are written for v1 and will not work on current releases — use docling convert file.pdf --to md.
Why is my scanned PDF converting to empty output?
A scanned PDF has no text layer, so OCR must be forced. Run docling convert scan.pdf --ocr-mode full_page. If pages are images inside a larger PDF, also make sure OCR is enabled (it is by default) and that an OCR engine is installed.
How do I make conversion faster?
For digital PDFs add --no-ocr (often several times faster) and skip features you do not need, for example --no-tables. Use --device cuda or --device mps when you have a GPU, and tune --num-threads and --page-batch-size. Use --profiling to see where time actually goes.
Which OCR engine should I choose?
Start with auto. RapidOCR is a strong cross-platform default and is CPU-friendly. Use tesseract/tesserocr for many languages, ocrmac on macOS, and nemotron-ocr only in a CUDA environment. Compare them on your own documents in the OCR guide.
Do I need a GPU?
No. Docling runs on CPU. A GPU mainly speeds up OCR and enrichment models on large documents. On Apple Silicon you can use --device mps; on NVIDIA use --device cuda.
Where are the converted files written?
By default into the current directory, next to where you run the command. Use --output ./some/folder to choose a directory. Note that --output is a directory, not a file name.
How do I convert many files or a whole folder?
Pass a directory (docling convert ./inbox --output ./out), pass several paths at once, or use a shell loop for full control. The Basic commands and the batch recipes above cover bash, PowerShell and parallel runs.
How do I get chunks for a RAG system?
Use docling convert report.pdf --to chunks --chunks-type hybrid. The chunks preserve headings and table structure. You can cap their size with --chunks-max-tokens and choose the tokenizer with --chunks-tokenizer.
Can I run Docling completely offline?
Yes. Prefetch models with docling-tools models download --all on a connected machine, then on the isolated host set DOCLING_ARTIFACTS_PATH (and HF_HUB_OFFLINE=1) and point at the copied cache with --artifacts-path.
When should I use the VLM pipeline instead of the standard one?
Use --pipeline vlm for complex, visually rich pages where classic layout analysis struggles, or when you want a single end-to-end model. For ordinary digital PDFs the standard pipeline is faster and cheaper, so start there.
Does Docling upload my documents?
No. Docling processes documents locally by default and sends no telemetry. Remote models are only used when you explicitly enable them with --enable-remote-services or point a pipeline at an external service.
Is --force-ocr still supported?
It is deprecated. Use --ocr-mode full_page, which is the supported way to OCR every page and replace any existing text.

Verified with Docling v2.129.0 · Last checked 2026-09-22 · Official source