Utility Merge Video

Utility Merge Video is a simple, reliable ComfyUI workflow for stitching clips end-to-end. It uses two or four LoadVideo nodes to decode your source files into frame batches, passes them into the Utility Merge Videos (Subgraph) node (ID: fbb76376-8768-4ece-9b41-a646f5e46ac3), and concatenates those frame sequences in order. The merged frames are then written to disk with SaveVideo.

Technically, the subgraph concatenates batches rather than compositing them, so the result plays one clip after another. A switch inside the Utility Merge Videos subgraph lets you choose between 2-input and 4-input modes. All inputs must share the same resolution; otherwise, the graph will error at merge time. The SaveVideo node controls the output file path, format (via extension), and playback FPS; the final FPS you set there determines how the concatenated frames will play back. A MarkdownNote node in the graph provides quick reminders right where you work.

API

Use this workflow from code

Every Comfy workflow is a JSON graph. The payload below is this workflow, exactly as ComfyUI runs it — fetch it from the URL, keep it in version control, or load it in ComfyUI and run it node by node.

81ba03930d2b.json
Fetching workflow JSON…

Run it from TypeScript or Python with the Comfy SDK. The same code targets Comfy Cloud or a ComfyUI you host yourself — only the base URL changes.

// Install (beta)
npm i @comfyorg/sdk

// Run this workflow (TypeScript)
import { Comfy } from "@comfyorg/sdk";

const client = new Comfy({ apiKey: "comfyui-..." });
const wf = await client.workflows.fromFile("workflow_api.json");
const job = await client.run(wf);
await job.getOutputs("<output-node-id>")[0].toFile("output.png");

The SDK takes a workflow in API format: open this workflow in ComfyUI and use File → Export Workflow (API).

Comfy Cloud API access requires a plan with an API key.

FAQ

Frequently Asked Questions

View all workflows
Showing 30 of 30 templates