docker exec -u node -it n8n n8n export:workflow --all

Category: n8n & Workflow Automation

docker exec -u node -it n8n n8n export:workflow --all

Run n8n CLI inside the container

Executes an n8n CLI command inside the running container as the node user, the documented way to use server CLI commands with a Docker install. The -u node flag makes files get created with the container's owning user. Swap export:workflow --all for any other CLI command.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.