Deploy Docling
Convert PDF, Office files and scans to Markdown/JSON. API key, web UI
Just deployed
Deploy and Host Docling on Railway
Docling is an open-source document conversion toolkit from the Docling project (LF AI & Data). It reads PDF, DOCX, PPTX, XLSX, HTML, images and scanned pages, works out layout, reading order and tables, runs OCR where needed, and exports clean Markdown, JSON, HTML or text. Docling Serve wraps it in an HTTP API and web UI.
About Hosting Docling
This template runs Docling Serve v1.38.2, the CPU build of the official image, as one public service with a Railway domain. The layout, table, picture-classifier and OCR models ship inside the image, so the service needs no downloads at boot and reports ready about 15 seconds after it starts. Every API call needs the X-Api-Key header. The key is generated at deploy time, and the service refuses to start without one. Docling Serve is stateless, so there's no database or volume. Plan for 2 to 4 GB of RAM, more for large documents. The first build pulls a 4.4 GB image and takes a few minutes.
Common Use Cases
- Turn PDFs, Office files and scans into Markdown or JSON for RAG pipelines and vector databases
- Give LLM agents and automation tools (n8n, LangChain, LlamaIndex) a private document parsing API
- Extract tables and structured text from reports, invoices and papers without sending files to a third-party service
Dependencies for Docling Hosting
- Docling Serve container image (CPU build), built from a public GitHub repo
- About 2 to 4 GB of RAM
Deployment Dependencies
- Docling Serve: https://github.com/docling-project/docling-serve
- Release v1.38.2: https://github.com/docling-project/docling-serve/releases/tag/v1.38.2
- Configuration reference: https://github.com/docling-project/docling-serve/blob/main/docs/configuration.md
- Template repo: https://github.com/aalfath/docling-railway-template
Implementation Details
Open https://YOUR-DOMAIN/ for the web UI and paste the API key (Variables tab, DOCLING_SERVE_API_KEY) into its server panel. API docs are at /docs.
curl -X POST https://YOUR-DOMAIN/v1/convert/file \
-H "X-Api-Key: YOUR-API-KEY" \
-F "files=@document.pdf" -F "to_formats=md"
Other services in the project can call http://${{Docling.RAILWAY_PRIVATE_DOMAIN}}:5001 over the private network. Any Docling Serve setting can be added as a variable, for example DOCLING_SERVE_MAX_NUM_PAGES or UVICORN_WORKERS. Updates arrive as commits to the template repo, and Railway shows an "update available" notice when one lands.
Why Deploy Docling on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying Docling on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Template Content

