> ## Documentation Index
> Fetch the complete documentation index at: https://docs.noclick.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Error handling

> Catch workflow failures with the On Error node and control per-node retry and failure behavior.

## The On Error node

The On Error node is a workflow-level error catcher. Add one per workflow and leave it disconnected from your main flow; the nodes you wire after it form a recovery path that is excluded from normal runs.

When any node fails and stops the run, the On Error node executes with the failure details as its output, and its downstream path runs. Use it for Slack alerts, error emails, or logging.

Its output carries:

| Field            | What it is                                  |
| ---------------- | ------------------------------------------- |
| `error`          | The error message                           |
| `workflow_id`    | The workflow that failed                    |
| `execution_id`   | The failed run's ID                         |
| `nodes_executed` | How many nodes completed before the failure |
| `duration`       | Run duration in seconds                     |

Reference these downstream, e.g. a Slack message with `Workflow failed: {{on-error-id.error}}`.

## Route failures to another workflow

You can also hand a workflow's failures to a separate workflow, so one recovery flow handles alerts for many. Open the canvas menu, choose **Settings**, and set **On error, run another workflow** to a workflow that has an On Error node.

When the first workflow fails, the chosen workflow's On Error node fires with the same failure details as its output. The target needs an On Error node, you need access to it, and routing is one hop, so a workflow reached this way does not chain on to a third.

## Per-node failure settings

Every node also has a **Settings** view in its config panel with failure controls:

| Setting           | What it does                                                                                        |
| ----------------- | --------------------------------------------------------------------------------------------------- |
| **Retry on Fail** | Re-run the node on failure. **Max Tries** up to 5, with a configurable **Wait Between Tries (ms)**. |
| **On Error**      | What happens after the final failed attempt (below)                                                 |

The **On Error** options:

* **Stop Workflow** (default): the run fails. The On Error node fires if present.
* **Continue (Regular Output)**: the node is treated as succeeded with an empty output and the run continues.
* **Continue (Error Output)**: the node outputs `{error, error_type}` and the run continues. If you wire an edge from the node's error handle, failures route down that path instead of the normal one.

**Example:** an HTTP request with **Retry on Fail** (3 tries) and **Continue (Error Output)**, whose error handle feeds a fallback notification while the success path continues unaffected.

## Next steps

* [Execution logs](/editor/execution-logs)
* [Branching](/logic/branching)
