Nodes/ComfyUI-Practical-Tools/Folder Video Concat
ComfyUI Node

Folder Video Concat

Stitch a folder full of clips into one MP4 without leaving the graph

By wenchengxiang·Created about a month ago·Updated a day ago· 0
Folder Video Concat
    • video
    folder_path

    Generated video is short - a few seconds a clip, on a good day - so every serious video workflow ends in the same place: a folder full of segments that are supposed to be one continuous shot. Folder Video Concat is the "combine them" step that never leaves ComfyUI. Give it a directory, it runs FFmpeg to join every clip inside into a single MP4, and hands the result back to the graph as a native VIDEO. No breaking out to a terminal, no importing into DaVinci Resolve just to glue two files together.

    It's a niche tool for a very real chore. Multi-part workflows are the norm with LTX, Wan, AnimateDiff and the rest - scene 1, scene 2, alternate takes - and until now the standard answers were VideoHelperSuite or an external editor. This one is for when the clips already sit in one folder and you want a single file that ComfyUI itself can keep reading downstream.

    How it works. The node reads the folder (absolute path, or relative to the ComfyUI root so output/folder works), keeps only video extensions - .mp4/.mov/.mkv/.avi/.webm/.m4v/.ts/.mts/.m2ts/.flv/.wmv - and natural-sorts by filename. Then it locates FFmpeg (your system PATH first, otherwise it walks up the directory tree looking for one), writes a concat list, and runs FFmpeg's concat demuxer with -c copy. That flag is the whole philosophy: lossless stream copy, zero re-encoding. Fast, no generational quality loss, and it means the tool lives or dies on whether your clips are actually compatible (more on that below). The finished file lands as merged_<random>.mp4 in ComfyUI/output/folder_video_concat/, and unlike temp output it's kept on disk because the returned VIDEO object just points at that path for downstream nodes.

    The inputs that matter. Once again, the UI is just one box:

    • folder_path (STRING) - the only input. Absolute path or one relative to the ComfyUI root. Quotes, env vars and ~ are handled; a missing folder or a folder with no video files fails loudly.
    • video (VIDEO) - the output. Wire it into any node that eats the native VIDEO type (preview, further processing).

    Installing it. It's part of ComfyUI-Practical-Tools, so the pack install applies: ComfyUI Manager → search "ComfyUI-Practical-Tools" → install, or

    cd ComfyUI/custom_nodes
    git clone https://github.com/wenchengxiang/ComfyUI-Practical-Tools
    

    then restart. No pip dependencies beyond what ComfyUI bundles - but this node has one external runtime requirement the pack will not install for you: FFmpeg must exist on your PATH. If you've never installed it separately, do that first. And it needs a reasonably recent ComfyUI, because the native VIDEO type is new; the code flat-out refuses to run on versions that don't support it.

    Where people get burned. The -c copy shortcut is both the feature and the trap. Stream-copy concatenation demands every clip match on codec, resolution, frame rate and pixel format. Mix a 720p h264 clip with a 1080p one - or an h264 file with an h265 one - and FFmpeg bails, and the node surfaces FFmpeg's raw stderr as the error. It usually says exactly what mismatched, but there's no re-encode fallback; this node is deliberately lossless-only. Also note the output filename is a random UUID and every run leaves another file behind in output/folder_video_concat/ - iterate twenty times and you've got twenty MP4s eating disk. And since ordering comes from natural filename sort, zero-pad your segment names (clip_01, clip_02) or the "concat" order will surprise you.

    Honest caveat for a node this obscure: the pack has essentially no community footprint and a one-line README, so judge it by its code. For this one the code is genuinely clean - the errors are informative and it fails safe instead of silently corrupting. Just keep the FFmpeg compatibility rule in mind and it does exactly one thing well.

    CategoryPractical-Tools/video

    Inputs (1)

    NameTypeDefaultDescription
    folder_pathSTRING

    Outputs (1)

    NameTypeDescription
    videoVIDEO