Skip to content
n8n integration

Convert files in n8n with switchfile

Add the Switchfile node to a workflow to turn the files it handles into the formats you need, and start workflows when a conversion finishes.

Verified node, available on n8n Cloud. Free for 20 files a day.

How to add it

The node comes as the package n8n-nodes-switchfile. On n8n Cloud you find it in the editor; on your own instance you install it once in the settings.

n8n Cloud

  1. In a workflow, open the nodes panel with + or by pressing N.
  2. Search for switchfile. The node is listed under More from the community.
  3. Select it, then Install. Only the owner or an admin of the instance can install it; after that everyone can use it.

Self-hosted n8n

  1. Open Settings, then Community Nodes, and select Install.
  2. Enter the package name below and confirm.
n8n-nodes-switchfile
The node needs a switchfile account and an API key. After you sign up, create a key under API keys and paste it into a new Switchfile API credential in n8n. A sandbox key (sf_test_) converts like a live key but never uses credits or your free files. The node needs file storage: if your account is set to convert without storing files (no_store), the API turns down its conversions.

What the node does

Convert File

Takes the file from a binary field, for example an email attachment or a download, and puts the converted file in a binary field. A result with several files, such as one image per page, gives one item per file.

Convert URL

Converts the file behind a public http or https address, without downloading it in n8n first.

Get Conversion

Looks up a conversion by its ID. It can wait until the conversion is finished and add the result files.

Switchfile Trigger

Starts a workflow when a conversion finishes, and if you choose, when one fails. Every request is checked against the signature of your account.

Tool for AI agents

Add the node as a tool of an AI Agent node, and the agent converts files when a task calls for it.

Presets and settings

Choose a preset from your dashboard or pass settings such as {"quality": 80}. The settings for each format are in the format docs.

Workflows to start with

PDF tables from email to Excel

  1. Email Trigger (IMAP)
  2. Switchfile: Convert File
  3. If
  4. Google Drive: Upload

Invoices or statements that arrive as PDF attachments become Excel workbooks. Tables land in cells, with numbers and dates as values you can calculate with.

  • Email Trigger: turn on Download Attachments. The first attachment is in the binary field attachment_0.
  • Switchfile: Input Binary Field attachment_0, Target Format xlsx.
  • If: continue only when {{ $json.result.incomplete }} is false. A result can be marked incomplete, for example when a page took too long; send those to a person instead.
  • Want the rows in the workflow instead of a file? Use Target Format json and read the result with Extract from File.

Word files in a Drive folder to PDF

  1. Google Drive Trigger
  2. Google Drive: Download
  3. Switchfile: Convert File
  4. Google Drive: Upload

Word files that appear in a shared folder get a PDF copy in a second folder. The trigger checks the folder regularly and picks up files whose creation time is after its last check.

  • Google Drive Trigger: event File Created, watching one folder.
  • Switchfile: Input Binary Field data, Target Format pdf.
  • Google Drive Upload: Input Data Field Name data, the folder for the PDF files.

Long videos without a waiting workflow

  1. Switchfile: Convert File
  2. Switchfile Trigger
  3. Switchfile: Get Conversion

Large videos can take longer than you want a workflow to wait. Start the conversion in one workflow and pick up the result in another.

  • Set up and activate the second workflow first: Switchfile Trigger on Conversion Finished, then Get Conversion with Conversion ID {{ $json.data.id }} and Download Result on. A conversion started before the trigger was active does not reach it.
  • Check under Webhooks in your dashboard that conversion.finished is selected. Activating the trigger sets the webhook URL and adds the conversion events only when none of them was selected. If your account already sends webhooks to another address, activation stops unless you turn on Replace Existing Webhook URL.
  • First workflow: Convert File with Wait for Completion off. The node returns right away with status queued.

Pricing

  • Free

    20files/day

    free API key

  • Credit pack

    from€7

    500 credits, one-time, no subscription

  • Monthly

    from€4

    500 credits a month, cancel at any time

The node uses credits like every other API request. Credits follow the conversion time: one credit per started minute. Each conversion costs at least 1 credit, and converting Office files or ebooks to PDF costs at least 2 credits. Converting a PDF to an Office file costs at least 2 credits.

See all prices

Waiting and large files

By default the node waits until the conversion is finished, up to 30 minutes, and you can change that under Options. Files up to 50 MB go with the request; larger files are uploaded first, up to the file size limit of your plan.

Read the API docs

Questions

About switchfile in n8n.

Is the switchfile node verified by n8n?

Yes. n8n reviewed the node, and on n8n Cloud it is listed in the nodes panel. On a self-hosted instance you install the same package, n8n-nodes-switchfile.

Who can install it?

On n8n Cloud, the owner or an admin of the instance installs the node once. After that, every member can use it in their workflows.

Which formats can the node convert?

The same formats as the switchfile API. Enter the file extension of the target format, for example pdf or mp4, or choose a preset from your dashboard.

What does it cost?

An API key converts 20 files and 20 minutes of conversion time a day for free, whichever runs out first. Long videos can use up the minutes before the files. Beyond that, conversions use credits. Keys that start with sf_test_ are sandbox keys and never use credits, which helps while you build a workflow.

Where are my files processed?

On our servers in the EU. Files and results are deleted after 24 hours.

Can an AI agent in n8n use the node?

Yes. Add the Switchfile node as a tool of an AI Agent node, and the agent can convert files and URLs when a task needs it.

Try it in your next workflow

A free API key converts 20 files a day.

n8n is a trademark of n8n GmbH. switchfile is not made by n8n.