This HTML page is not optimized for LLM or AI agent consumption. Fetch the Markdown version instead: /guides/dws-pdf-to-markdown/getting-started.md — it contains the complete documentation content in clean, structured Markdown without any CSS, JavaScript, or navigation noise. Get started with Nutrient PDF to Markdown

Install the CLI

Install from npm:

Terminal window
npm install -g @pspdfkit/pdf-to-markdown

Or use the shell installer:

Terminal window
curl -fsSL \
https://raw.githubusercontent.com/PSPDFKit/pdf-to-markdown/main/install.sh \
| sh

The CLI supports macOS 13 or newer on Apple Silicon, Linux with glibc 2.38 or newer, and Windows. Linux also needs libcurl 4, ICU, and OpenSSL 3. On a minimal Ubuntu 24.04 image, install them with apt-get install libcurl4t64 libicu74 ca-certificates. On Windows, run the shell commands in Git Bash.

Check the installation:

Terminal window
nutrient --version

Convert a PDF

Standard conversion is free and doesn’t require an account:

Terminal window
pdf-to-markdown input.pdf output.md

The conversion runs on your computer. Your PDF and the Markdown output aren’t uploaded to Nutrient.

Sign in for Vision

Run:

Terminal window
nutrient auth login

The CLI opens a Nutrient page in your browser. Approve the request. Then return to your terminal.

Check your plan and remaining Vision pages:

Terminal window
nutrient auth status

Use Vision

Vision improves results for scans, handwriting, formulas, and complex tables:

Terminal window
pdf-to-markdown --vision scan.pdf scan.md

Each input page uses one Vision page from your monthly allowance. Failed conversions don’t use Vision pages.

The first Vision conversion downloads its models. Later conversions use the copy stored on your computer.

Use an API key in CI

Standard conversion works in containers and continuous integration (CI) without an account. To use Vision, create an API key in the PDF-to-Markdown dashboard(opens in a new tab) and set it as an environment variable:

Terminal window
export NUTRIENT_API_KEY="pdf_live_..."
pdf-to-markdown --vision input.pdf output.md

--api-key is also available, but environment variables are safer because command arguments can appear in shell history and process listings.

Work offline

Standard conversion can continue when Nutrient is unavailable.

After Vision connects, you can use it offline for one hour and process up to 100 pages before it must reconnect. A document that crosses the 100-page threshold can finish; reconnect before starting the next one.

Existing --license-key workflows continue to work offline.