Skip to main content

Error Handling

Build resilient automations that handle failures gracefully instead of crashing.

Retry Logic

Flow Builder

Configure retries on any action step:

  1. Click the step you want to configure
  2. Open Settings (gear icon)
  3. Enable Retry on Failure
  4. Set:
    • Max retries — 1 to 5 attempts
    • Delay — Seconds between retries (e.g., 5s, 30s, 60s)

Workflow Builder

Right-click any node → Settings:

  • Retry on Fail — Enable automatic retries
  • Max Tries — Number of retry attempts (1–5)
  • Wait Between Tries — Milliseconds between retries
  • Continue on Fail — Don't stop the workflow if retries are exhausted

Error Paths

Workflow Builder Error Handling

Create alternative paths for when nodes fail:

HTTP Request ──success──→ Process Response

└──error──→ Log Error → Send Alert Email

To add an error output:

  1. Right-click the node
  2. Select Add Error Output
  3. Connect the error output to your fallback logic

The error output receives:

{
"error": {
"message": "Request failed with status 500",
"name": "NodeApiError",
"node": "HTTP Request",
"timestamp": "2026-04-21T10:30:00Z"
}
}

Error Trigger Workflow

Create a dedicated workflow that runs when any automation fails:

  1. Create a new workflow
  2. Add an Error Trigger node
  3. Add actions: send Slack alert, create Jira ticket, send email, etc.
  4. Activate the workflow

The Error Trigger receives details about the failed workflow:

  • Workflow name and ID
  • Node that failed
  • Error message and stack trace
  • Execution timestamp

Common Error Patterns

Rate Limiting

Many APIs enforce rate limits. Handle them with exponential backoff:

// Code node with retry logic
const maxRetries = 3;
let delay = 1000; // Start with 1 second

for (let i = 0; i < maxRetries; i++) {
try {
const response = await fetch('https://api.example.com/data');
if (response.status === 429) {
await new Promise(r => setTimeout(r, delay));
delay *= 2; // Exponential backoff
continue;
}
return [{ json: await response.json() }];
} catch (error) {
if (i === maxRetries - 1) throw error;
}
}

Timeout Handling

For long-running operations, set appropriate timeouts:

  • HTTP Request node: Set Timeout in milliseconds
  • Code node: Use AbortController for fetch requests
  • Default timeout: 300 seconds (5 minutes) for most operations

Missing Data

Validate that required data exists before processing:

// IF node condition
{{ $json.email }} is not empty

// Code node validation
if (!$json.email) {
throw new Error('Email is required but was not provided');
}

Monitoring Failures

All errors are recorded in the run history:

  1. Go to Dashboard → Automations → View Runs
  2. Filter by Failed status
  3. Click a failed run to see:
    • Which step failed
    • The error message
    • Input data that caused the failure
    • Timestamp and duration

Set up alerts in Observability → Alerts to get notified of failures via email, Slack, or webhook.