Tips > Reliability & Performance

Always Set an Error Workflow on Every Production Workflow

This is the single most commonly missed best practice in n8n.

TipAdvanced2 min read

This is the single most commonly missed best practice in n8n. Every production workflow should have an Error Workflow configured in its settings. Without it, failures are silent -- they appear in the execution log, but nobody is notified. The error workflow runs automatically when any unhandled error occurs, giving you a chance to alert, log, and recover.

Real-world example: An order processing workflow fails at 2am because the payment API returns an unexpected error. Without an error workflow, the order is silently lost. With one, the on-call engineer gets a Slack message within seconds.

Configure the error workflow in the workflow settings:


# Workflow Settings (gear icon in the top-right of the editor)

Error Workflow: "Error Handler - Alert Team"

# This setting tells n8n: "If any node in this workflow throws

# an unhandled error, trigger the Error Handler workflow."

```text
The error workflow receives an Error Trigger node with this data structure:

```json
{
  "execution": {
    "id": "231",
    "url": "https://n8n.example.com/execution/231",
    "retryOf": null,
    "error": {
      "message": "Request failed with status code 502",
      "stack": "Error: Request failed with status code 502\n    at ..."
    },
    "lastNodeExecuted": "HTTP Request - Payment API",
    "mode": "trigger"
  },
  "workflow": {
    "id": "15",
    "name": "Order Processing Pipeline"
  }
}
```text
> **Warning: This does not apply to manual test executions**
>
> Error workflows only trigger for production executions (triggered by webhooks, schedules, or other triggers when the workflow is activated). Manual test runs in the editor show errors inline but do not trigger the error workflow. Test your error workflow by temporarily introducing a failure in an activated workflow.

Set this on every single production workflow. No exceptions. It takes 30 seconds and prevents silent failures from going unnoticed for hours or days.

**Related:** [Use "Pin Data" to Freeze Node Output](../testing-and-debugging/01-use-pin-data-to-freeze-node-output.md) | [Break Large Workflows into Sub-Workflows](../workflow-architecture/01-break-large-workflows-into-sub-workflows.md)

Want this running in your stack?

I build production n8n and Cloudflare automation for teams — the same engineering behind HarperFlow. Fixed-price, escrow-protected, US-based.