Recipes

Using MarkItDown in n8n

Updated 2026-11-16·Upstream source ↗
Markdown view

n8n has no built-in MarkItDown step. We tested one way to add it: the Execute Command node running the markitdown command. It worked, but only after we enabled the node, because n8n 2.35.7 does not load it by default. The other routes people use, a community node or an HTTP call to your own service, we did not test.

Short answer

The Execute Command node must be switched on and markitdown must be installed where n8n runs. With the node enabled, a workflow running /path/to/markitdown /path/to/file.docx returned the Markdown in the node's stdout.

Tested with markitdown 0.1.9 · Python n8n 2.35.7 installed with npm on a GitHub-hosted Ubuntu 24.04 runner, Node 22, Python 3.13, markitdown 0.1.9. Not Docker, not n8n cloud (T23) · 2026-11-16 · evidence: n8n.log, n8n-workflow.json

What we ran

A two-node workflow: a Manual Trigger and an Execute Command node with the command markitdown /tmp/data/report.docx, run with n8n execute. MarkItDown 0.1.9 was in a virtual environment on the same machine.

The workflow we imported
{"id":"md1","name":"markitdown execute command","active":false,"nodes":[
 {"parameters":{},"id":"n1","name":"Manual Trigger","type":"n8n-nodes-base.manualTrigger","typeVersion":1,"position":[0,0]},
 {"parameters":{"command":"/opt/mdv/bin/markitdown /data/report.docx"},"id":"n2","name":"Execute Command","type":"n8n-nodes-base.executeCommand","typeVersion":1,"position":[240,0]}],
 "connections":{"Manual Trigger":{"main":[[{"node":"Execute Command","type":"main","index":0}]]}},"settings":{},"pinData":{}}
n8n-workflow.json · 507 bytes output (.md)

The node is off by default

On n8n 2.35.7 the first run failed with the node unrecognised:

Unrecognized node type: n8n-nodes-base.executeCommand

Setting NODES_EXCLUDE='[]' (which clears n8n's default exclusion list) made the node available:

Command
NODES_EXCLUDE='[]' n8n execute --id=md1

The run finished with status success, and the Markdown of our Word report was in stdout. The output also carried a stderr line from the file-type model's runtime, which is harmless.

The runs
date: 2026-11-16
### install-n8n
$ npm install -g n8n 2>&1 | tail -3; n8n --version

361 packages are looking for funding
  run `npm fund` for details
2.35.7
[exit 0, 147s]

### import
$ n8n import:workflow --input=/tmp/data/workflow.json 2>&1 | tail -5
Finished migration AllowDiscordAgentChatSubscriptions1785840970000
Starting migration AddReasonToWorkflowPublicationOutbox1786519946974
Finished migration AddReasonToWorkflowPublicationOutbox1786519946974
Importing 1 workflows...
Successfully imported 1 workflow.
[exit 0, 5s]

### default-execute-command
$ n8n execute --id=md1 2>&1 | tail -25
Failed to load Custom API options for the node "n8n-nodes-base.confluence": Unknown credential name "confluenceCloudOAuth2Api"
n8n Task Broker ready on 127.0.0.1, port 5679
Failed to start Python task runner in internal mode. because its virtual environment is missing from this system. Launching a Python runner in internal mode is intended only for debugging and is not recommended for production. Users are encouraged to deploy in external mode. See: https://docs.n8n.io/hosting/configuration/task-runners/#setting-up-external-mode
[license SDK] Skipping renewal on init: renewOnInit is disabled in config
[license SDK] Skipping renewal on init: autoRenewEnabled is disabled in config
[license SDK] Skipping renewal on init: license cert is not initialized
Error executing workflow. See log messages for details.

Execution error:
====================================
Unrecognized node type: n8n-nodes-base.executeCommand
Error: Unrecognized node type: n8n-nodes-base.executeCommand
    at LazyPackageDirectoryLoader.getNode (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/node_modules/n8n-core/src/nodes-loader/directory-loader.ts:256:9)
    at LoadNodesAndCredentials.getNode (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/src/load-nodes-and-credentials.ts:631:29)
    at NodeTypes.getByNameAndVersion (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/src/node-types.ts:98:45)
    at new Workflow (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/node_modules/n8n-workflow/src/workflow.ts:94:30)
    at WorkflowRunner.runMainProcess (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/src/workflow-runner.ts:359:20)
    at WorkflowRunner.run (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/src/workflow-runner.ts:290:15)
    at Execute.run (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/src/commands/execute.ts:105:23)
    at CommandRegistry.execute (/opt/hostedtoolcache/node/22.23.4/x64/lib/node_modules/n8n/src/command-registry.ts:97:4)
n8n.log · 5,141 bytes · first 40 of 89 lines shown output (.md)

Cautions

  • The node runs arbitrary commands: never put a file name or text from outside into the command string. Use a fixed temporary file name.
  • The MarkItDown command must exist on the machine where n8n runs. The current n8n Docker image has no package manager, so we could not simply add Python to it with apk; we ran n8n from npm instead. A custom image is another way, which we did not build.
  • Scanned PDFs come back empty without an error (OCR).

Routes we did not test

A community MarkItDown node, and an HTTP Request node calling a conversion service you run yourself, for which the FastAPI recipe is a starting point. The HTTP route keeps MarkItDown out of the n8n machine, which suits shared instances; that is reasoning, not a test. We also did not test n8n cloud.