---
title: "End"
description: "Define workflow outputs and termination points"
icon: "flag-checkered"
---

The End node defines what your workflow outputs when it completes. Every workflow application needs at least one End node to return results to users and terminate execution.

<Info>
  End nodes are only for Workflow applications. Chatflow applications use Answer nodes instead to deliver responses during conversation flow.
</Info>

## Output Configuration

The End node collects outputs from previous workflow nodes and packages them into the final response. Configure which variables to output by referencing data from upstream nodes using the variable selector or `{{variable_name}}` syntax.

You can output multiple variables of different types including text, numbers, objects, arrays, and files. Each output variable becomes part of the workflow's final result structure.

## Single vs Multiple End Nodes

### Single Path Workflows

Simple workflows with one execution path need only one End node to capture the final result:

<Frame caption="Single path workflow with one End node">
  <img src="https://assets-docs.dify.ai/dify-enterprise-mintlify/en/guides/workflow/node/9e43961344d318e09af8d64464d81774.png" alt="Single path workflow example" />
</Frame>

### Multi-Path Workflows

Workflows with conditional branches require End nodes for each possible execution path. Each branch can output different variables depending on the workflow logic:

<Frame caption="Multi-path workflow with multiple End nodes">
  <img src="https://assets-docs.dify.ai/dify-enterprise-mintlify/en/guides/workflow/node/3cb3f5fea376265bede0a4ac5bcc1ddc.png" alt="Multi-path workflow example" />
</Frame>

## Execution Behavior

Once workflow execution reaches an End node, processing immediately stops. No nodes connected after an End node will execute. This makes End nodes natural termination points for different workflow branches.

If your workflow has multiple possible execution paths (through If-Else nodes, for example), ensure each path leads to an End node. Otherwise, some execution branches may not return results.

## Output Examples

**Text Processing Results** - Output processed text, summaries, or analysis results from LLM nodes.

**Structured Data** - Return JSON objects, arrays, or extracted parameters from various processing nodes.

**File Outputs** - Deliver generated documents, images, or other files created during workflow execution.

**Status Information** - Include processing metadata, success indicators, or diagnostic information.

<Frame caption="Complex workflow output example">
  <img src="https://assets-docs.dify.ai/dify-enterprise-mintlify/en/guides/workflow/node/a103792790447c1725c1da1176334cae.png" alt="End Node - Long Story Generation Example" />
</Frame>

## Best Practices

**Consistent Output Structure** - Use similar variable names and data types across different End nodes in the same workflow for predictable API responses.

**Include Status Information** - Consider outputting success indicators or processing metadata alongside main results.

**Handle All Paths** - Ensure every possible execution path in your workflow leads to an End node to prevent incomplete executions.

**Document Output Schema** - Clearly document what each End node returns for API consumers and integration purposes.