How to Set Up Automated Alerts for n8n Workflow Errors
n8n Workflows can fail to run for a variety of reasons - an offline application, expired API credentials, or a misconfigured node.
If you rely on n8n to connect your apps and automate critical tasks, a failing workflow can disrupt your entire business process.
The Issue: Silent Workflow Failures in n8n
By default, when an n8n workflow fails, it does so silently.
n8n simply marks the workflow's Execution as an "Error" and halts that specific process while carrying on with other tasks. The system does not natively push a notification to the user.
To discover a failure, users are traditionally forced to proactively log into their n8n environment, navigate to the executions list, and hunt for "Error" statuses. For time-sensitive automations, this delay in discovery is unacceptable.
The Solution: Triggering an Error Workflow
Fortunately, n8n provides a built-in mechanism to catch and handle these failures gracefully. By utilizing the Error Workflow setting, you can instruct n8n to automatically trigger a designated secondary workflow whenever your primary workflow fails.
This secondary "Error Workflow" can be configured to send an immediate alert directly to your phone or inbox, ensuring you know the moment an automation breaks.
Why Use TNZ for Your n8n Alerts?
When an internal system fails, relying on that same system to send you an alert is risky.
By integrating TNZ's CPaaS platform as your alerting mechanism, you gain several crucial advantages:
- Out-of-Band Messaging: TNZ alerts operate independently of your internal n8n integrations. If your internal email server node is the cause of the n8n error, TNZ will still successfully deliver the failure alert to your phone.
- Omnichannel Alerts: TNZ supports SMS, Email, Voice, and WhatsApp. You do not need multiple providers or complex routing. All message types can be managed through a single TNZ workflow.
- Severity-Based Routing: Match the alert type to the workflow's importance. Use an automated Voice call (which rings your phone) for mission-critical workflow failures, SMS for standard errors, and Email for low-priority warnings.
- Rapid Deployment: Resolve the silent error issue in minutes using TNZ's premade n8n error workflow template.
How to Configure TNZ Error Alerts in n8n
Follow these steps to import the TNZ error alerting template and apply it to your important workflows.
Step 1: Import the TNZ Workflow into n8n
- Log into your n8n workspace and click Add Workflow to create a new, blank workflow.
- Click the More Actions button (the vertical ellipses ⋮ in the top right corner).
- Select either:
- Import from File and upload this file:
trigger-on-workflow-error.json
- Import from URL and insert this link:
trigger-on-workflow-error
Step 2: Authenticate the TNZ Nodes
Once imported, you will see the pre-built TNZ nodes for SMS, Voice, and Email alerts.
- Open each TNZ node in the workflow.
- Locate the Auth values and insert your personal TNZ Auth Token.
- Need help finding your token? Read our guide on Generating Your TNZ Auth Token.
- Save this workflow. Make sure the workflow is named exactly
trigger-on-workflow-error. Don't worry if the workflow is Inactive, it's designed to be called when required.
Step 3: Assign the Error Workflow to Your Automations
Now that your alerting workflow is active, you need to tell your other workflows to use it.
- Open any important workflow you want to monitor.
- Click the More Actions (⋮) button and select Settings.
- Find the field labeled Error Workflow (to notify when this one errors).
- Select
trigger-on-workflow-error from the dropdown menu.
- Save your workflow.
Success! Your workflow is now monitored. If it encounters a failure, n8n will immediately pass the error data to TNZ, and you will receive an alert on your preferred channel.
Note: You can customise your alerts with additional API variables.