How to download and export workflows from n8n

If you’re building automations regularly with n8n, there will come a time when you need to export your workflows—perhaps for backup, migration, collaboration, or version control. Fortunately, n8n makes workflow export and download a breeze. Whether you're using the desktop app, cloud version, or a self-hosted setup, this guide will walk you through everything you need to know about n8n workflow download and export.

Let’s dive into the various ways to download your workflows from n8n step-by-step.

Why Download or Export Workflows in n8n?

Downloading workflows isn’t just a nice-to-have feature—it’s essential, especially when:

  • Backing up workflows as part of your disaster recovery plan
  • Sharing workflows with teammates or the n8n community
  • Moving workflows from dev to prod environments
  • Migrating to another automation tool like Make.com
  • Keeping versioned snapshots for Git-based version control

Depending on your installation (n8n Cloud, Desktop, or Self-hosted), your export method may vary slightly, but the process largely remains straightforward.

Method 1: Download Workflows Using n8n UI

This is the easiest and most common method. It works whether you're on the cloud or self-hosted web UI.

Step-by-Step Guide

  1. Open your n8n dashboard by logging into your workspace.
  2. Find the workflow you want to export under "Workflows".
  3. Click the three-dot menu (…) next to the workflow name.
  4. Select “Download”.

This will trigger a .json file download, containing your entire workflow—nodes, connections, settings, and metadata.

🎯 Pro Tip: Rename your file using a consistent naming scheme like workflow-name_v1.json to keep track of versions.

Method 2: Export via n8n Desktop App

If you're using the n8n desktop version (Mac, Windows, or Linux), the procedure is the same:

Steps:

  1. Launch your n8n desktop app.
  2. Open the workflow you want to export.
  3. Use the File > Export menu or click the Download icon in the top right corner.
  4. Save the .json file to your desired location.

This comes in handy when running n8n in offline/local mode. If you're unsure how to run n8n locally, check out this guide.

Method 3: Export Multiple Workflows from Database (For Advanced Users)

If you’re self-hosting and want to export multiple workflows in bulk (e.g. scheduled backups), you can pull workflows directly from your n8n database.

Assuming you’ve set up n8n with a Postgres or SQLite backend:

Example SQL Query (PostgreSQL):

SELECT name, active, nodes, connections FROM workflow_entity;

You can then script the export of these workflows into JSON files using a Node.js or Python script that formats and writes them to disk.

This method is best used for automation backups or batch migrations.

To learn how to do this automatically, check out how to backup n8n workflows automatically.

Method 4: REST API Export (Great for Automation)

If you want to programmatically export a workflow (e.g. for CI/CD workflows), n8n also ships with a powerful REST API.

Example API Call:

GET /rest/workflows/:id
Authorization: Bearer <your-api-key>

This returns the workflow in JSON format. Just save the response body to a .json file.

Use Case Example:

You could build a CI/CD step to:

  • Pull latest workflows from your production URL
  • Commit them to a Git repo
  • Validate changes via unit tests or linters

This is a great way to enforce workflow integrity in enterprise environments.

Reimporting Workflows into n8n

Once you’ve downloaded a workflow, you can easily import it into any n8n instance.

Steps:

  1. In the n8n UI, go to the top-right menu.
  2. Click "Import", then choose “Import from file” or paste JSON.
  3. Your workflow will appear, ready for review or activation.

✅ Imported workflows are paused by default—remember to activate them manually!

Bonus: Versioning Workflows via Git

If you’re tech-savvy, here’s an extra trick. You can maintain workflow version history using Git:

  • Store your .json exports in a Git repo
  • Use feature branches for new automation changes
  • Include a changelog.md for each version
  • Create pull requests when collaborating with teams

This strategy makes n8n workflows shareable, trackable, and rollback-proof.

Quick Visual Summary

Here’s a simple table summarizing the export options for quick reference:

Method Ideal For File Format Requires Code?
n8n UI export All users .json
Desktop App export Local/offline use .json
DB-level export Bulk backups, server-level tasks .json
REST API export CI/CD, integrations JSON

Tip: Best Practices for Exporting Workflows

When dealing with n8n workflow downloads, these best practices can save you time and headaches:

  • Use consistent naming conventions for file storage
  • Store sensitive info as environment variables—these won't be baked into the .json files
  • Export regularly if workflows are mission-critical
  • Test imports in a dev instance before moving to production
  • Consider installing n8n on macOS or locally for quick, isolated testing

Choose the Platform That Grows With You

If you haven’t chosen a hosting setup yet or want more flexibility, consider using the modular and open-source nature of n8n. Whether you’re running it locally or on the cloud, exporting your workflows gives you full control over your automation strategy.

FAQ

How do I download a workflow in n8n?

You can download any workflow directly from the n8n UI by clicking the three-dot menu next to the workflow name and selecting “Download”.

Are the downloaded workflows saved with credentials or tokens?

No. Sensitive credentials are not stored in the exported .json files—they are referenced from the credentials manager within n8n.

Can I bulk export workflows from n8n?

Yes, using SQL queries in your n8n database or via the REST API, you can script the export of multiple workflows.

Can I share my n8n workflow with other users?

Absolutely. You can send the exported .json file to another user who can import it into their own n8n instance.

Is there a way to automate n8n workflow backups?

Yes, you can automate downloads through scripting or by using tools like CRON and the n8n REST API. Learn more in our workflow backup guide.

Comments
Join the Discussion and Share Your Opinion
Add a Comment

Leave a Reply

Your email address will not be published. Required fields are marked *