Docling, the open-source document converter from IBM Research, turns PDFs into Markdown or JSON with layout, table structure and OCR for scanned pages. OCR is on by default for scanned documents. This guide converts one scanned report to Markdown and checks the result.
Prerequisites
Python 3.10 or newer, Docling installed with pip install docling, and a scanned PDF. Work on a copy of the file.
Steps
1. Check the Docling install
Run docling –help in a terminal. Expected result: the Docling help text prints.
2. Convert the scanned PDF to Markdown
Run docling report.pdf –output ./out. Expected result: a file named report.md appears in ./out.
3. Check the headings in the Markdown
Open report.md and read the headings. Expected result: the six section headings appear as Markdown headings in order.
4. Check the table came out as a table
Find the revenue table in report.md. Expected result: the table appears as a Markdown table with four rows.
Practice check: fictional six-section scanned report with one table
The table below is fictional practice material. It lists the four checks for the Markdown file.
| Check | Expected result |
|---|---|
| Help prints | docling –help works |
| Markdown created | report.md in ./out |
| Headings in order | Six headings present |
| Table as Markdown | Four-row table present |
Expected result. the Markdown file is created, the six headings appear in order, and the revenue table appears as a four-row Markdown table.
Limits
- Docling reads the layout, not the meaning; a table that converts cleanly can still hold a misread figure, so check money figures against the scan.
- UNTESTED – no OCR tool or AI tool was run; all results above are expected results. The practice file is fictional.
Sources
- Docling documentation – Docling converts PDFs to Markdown or JSON with layout, table structure and OCR for scanned PDFs. Checked 2026-11-29.
- Tesseract OCR Documentation, output formats – Tesseract supports plain text, searchable PDF, hOCR, TSV, ALTO and PAGE output; –psm sets the page segmentation mode. Checked 2026-11-29.
