AI and Automation

n8n vs Zapier vs Custom Code: Pick Your Automation Stack

How to choose between Zapier, n8n and custom code: task arithmetic, error handling, self-hosting, who maintains it, and the signs it is time to move to code.

Most companies run automations, and many run them on the wrong layer. There are three layers to choose from: a hosted no-code tool such as Zapier, a workflow engine such as n8n that you can host yourself, and custom code running on your own queues. Each is right for a band of problems. The expensive mistakes happen at the boundaries: staying on a no-code tool two years too long, or writing custom infrastructure for a workflow that fires six times a day. This post sets out the criteria we use to choose between them.

The One-Paragraph Version

Zapier wins on time to first automation and on the breadth of ready-made integrations. It becomes expensive and hard to reason about at volume. n8n wins on control, on cost at scale, and on the ability to drop into code in the middle of a workflow. It asks for more technical skill and, when self-hosted, real operational ownership. Custom code wins when the workflow is the product, when volume gets serious, or when a failure costs money. It loses on iteration speed, because every change needs an engineer. Many companies end up running two of these tiers on purpose. Few have a good reason to run all three for the same class of problem.

Four Criteria That Separate the Options

1. Volume: Do the Arithmetic First

Zapier bills by task, so start by learning what a task is. According to Zapier’s documentation on task usage, each successful action step counts as one task. Triggers do not count, and neither do Filter, Paths, Formatter or Delay steps.

Take a modest workflow: a trigger, a filter, a formatter step and two actions. Only the two actions count. At 200 runs a day:

200 runs × 2 tasks × 30 days = 12,000 tasks a month.

Give the same workflow five action steps (an enrichment call, a CRM write, a spreadsheet row, a Slack message and an email) and the figure becomes 200 × 5 × 30 = 30,000 tasks a month. Volume on Zapier is runs multiplied by billable steps, and the second number is the one people forget.

n8n counts differently. Its cloud plans bill per workflow execution however many steps the workflow has, and a self-hosted instance has no per-execution fee: you pay for the server and for the time someone spends looking after it. Prices and plan limits on both sides change often, so we will not print them here. Check the current Zapier pricing and n8n pricing pages, and run your own multiplication against them.

As a rule of thumb, at a few thousand tasks a month the tool cost is small next to the time it saves, and convenience should decide. In the tens of thousands, per-task pricing becomes a budget line somebody will ask about, and the n8n or custom-code conversation is worth having.

2. Error Handling: The Criterion People Discover Late

Automations fail. APIs rate-limit, webhooks arrive twice, somebody renames a CRM field. The useful question is whether you find out before your customers do.

Zapier handles the basics: automatic replay of failed runs on some plans, alerts, and error-handler paths on individual steps. n8n goes further. You can set a dedicated error workflow that runs whenever another workflow fails, configure retries per node, and re-run a failed execution with its original data. Custom code gives you whatever you build: dead-letter queues, idempotency keys, exponential backoff, alerts to your on-call tool.

One question settles most cases: if this workflow failed silently for 48 hours, what would it cost? If the answer is mild annoyance, any tier will do. If the answer is lost orders or a compliance incident, you need n8n with error workflows at a minimum, and probably code.

3. Self-Hosting and Data Control

If workflows carry health information, financial records, or personal data with residency requirements, self-hosting n8n inside your own network changes the compliance conversation, because the workflow engine is no longer a third party that processes the data. The services the workflow calls still are. A self-hosted workflow that sends records to an external API has moved the question to that API. A hosted tool can offer contractual assurances, but it remains one more processor to assess. For healthcare work, our HIPAA engineering guide covers what that assessment involves.

The cost is operational. Self-hosting means you own updates, backups, uptime, and queue mode if one instance stops being enough. Budget a few hours a month of real attention, or use n8n’s hosted cloud and accept the middle ground.

4. Who Maintains It

Zapier’s great strength is that operations and marketing people build and fix their own automations. n8n sits in between: technical operators and developers are comfortable in it, and most non-technical staff are not, especially once a Code node appears. Custom code means every change joins an engineering backlog behind feature work, which is how a two-field change ends up taking three weeks. Match the tier to the team that will own the workflow, not the team that builds the first version.

Three Examples, One per Tier

Lead Routing: A Zapier-Class Problem

A form submission is enriched, scored, written to the CRM and announced in Slack. Suppose it fires 30 times a day, a failure costs a slightly delayed follow-up, and marketing owns the scoring rules and edits them monthly. Putting this in code would be a mistake, because every rule change would need a deploy.

An AI Content Pipeline: An n8n-Class Problem

Our own blog pipeline is the example we know best. A scheduled n8n workflow gathers candidate topics from several sources, scores them, runs two LLM stages, validates the output, checks for duplicates against existing posts, and saves the result as a draft. It stops there. A person reads the draft, edits it, and approves it before anything is published. The workflow has no publish step at all. We treat that as a design rule: automation prepares, a person decides.

The shape of the work is what makes it an n8n problem. It needs branching, a little custom scoring code, retries and API key management, and it changes every few weeks. That is too much for a linear zap and nowhere near enough to justify a custom service.

Document Processing: A Code-Class Problem

Suppose a company ingests thousands of PDFs a day: OCR, LLM extraction, validation against business rules, a write back to the ERP. At that volume, with money attached to each document, the right shape is a queue-backed service (for example BullMQ on Node, with Postgres and object storage) that has idempotency keys, dead-letter queues and metrics per stage. An n8n prototype is still a good way to validate the flow in the first week. After that the work belongs in code, because a visual canvas is a poor place to manage 40 concurrent workers and deduplication under retries.

That last example shows a pattern worth adopting: prototype on the visual tier, then graduate deliberately. n8n is a good way to discover what a workflow should be before you harden it.

When to Move to Code

  1. You are fighting the tool. Loops, state or branching need workarounds that would be five lines in a programming language. When a third of your nodes are Code nodes, the canvas is costing you more than it gives.
  2. You hit volume or concurrency walls: sustained thousands of executions a day, or long-running steps colliding with platform timeouts. Zapier’s per-step limits and a single n8n instance both have ceilings.
  3. Correctness requirements sharpen. Transactional writes across systems, audit trails and idempotency under retries can be approximated in a visual tool. In code you can test them.
  4. The workflow becomes product. When customers see its output directly, or it sits in the revenue path, it deserves tests, code review, CI and staged rollouts.
  5. Change frequency drops while criticality rises. A stable, critical workflow gains little from a canvas whose main virtue is easy editing.

How AI Steps Change the Math

LLM calls inside workflows shift the decision in two directions. On cost, a step that spends a few cents on model tokens can outweigh the platform’s per-task fee, which weakens the cost argument for leaving Zapier at moderate volumes. Pulling the other way, AI steps need things that visual platforms handle unevenly: prompt versioning, output validation, a fallback model for when a provider has an incident, and evaluation before a prompt change ships. (Choosing the models is a separate question, covered in GPT vs Claude vs Gemini.)

n8n covers the mechanics: LLM nodes plus a validation step handle most patterns. Once you need evaluation suites and staged prompt rollouts, you are in code territory whatever the volume. The risk is no longer that the workflow errored. It is that the workflow succeeded and produced confident, wrong output at scale, and that kind of failure appears in no platform’s error log.

Our practice follows from that. AI workflows whose output a person reviews can stay on n8n for as long as they like. AI workflows whose output goes straight to customers are built in code, behind an evaluation gate, at any volume. The chatbot launch checklist describes what that gate looks like for a customer-facing assistant.

What We Recommend by Company Shape

  • A small team with no engineers assigned to internal tooling: Zapier, or a similar hosted tool, for everything. Your constraint is attention, not task pricing. Revisit when the monthly invoice starts to get noticed.
  • A growing team with technical operators, sensitive data, or task counts in the tens of thousands: n8n (self-hosted or cloud) as the default tier, with Zapier kept for the automations marketing owns.
  • Anything customer-facing, revenue-bearing or high-volume: custom services with proper queues, prototyped on n8n first if the shape is uncertain.

One habit saves money whichever tier you choose: audit the stack twice a year. Automation sprawl is real. There are zaps nobody remembers and workflows that patch processes which no longer exist. A good stack is one where someone can say, for every workflow, what it does, what it costs, and who fixes it when it breaks at 2 am.

If you would like help designing this stack, or a review of one that grew without a plan, our AI and automation team builds on all three tiers. Request a call and tell us what you are automating.

All articles

Need Help With This?

Tell us what you are building. We reply within 24 hours and suggest a team or individual developers that fit the work.