Video to Base64 (BFL)
VIDEO in, base64 MP4 out
- video
- STRING
Some nodes are heroes, and some are plumbing. VideoToBase64_BFL is plumbing - a one-input, one-output utility whose entire job is turning a ComfyUI VIDEO into a base64 MP4 string. It exists for one reason: Flux3VideoV2V_BFL wants its start_video input as either a URL or a base64 blob, and nobody wants to hand-encode a video file just to feed a node.
It's part of the utils drawer in gelasdev's ComfyUI-FLUX-BFL-API pack, sitting right next to Image to Base64 (BFL), which does the identical job for stills. And while it's not flashy, it's the difference between a V2V workflow that flows and one where you're stuck wrestling with a file converter in the middle of your graph.
How it works
One input, video (VIDEO), and one output, STRING (the base64 MP4). The node is smart about what it does with the incoming video:
- If the VIDEO's stream source is already an MP4 sitting in memory or on disk, it just reads the bytes directly - no re-encoding, fast and lossless.
- Anything else (a different container, frames in memory, a LoadVideo output that isn't plain MP4) gets remuxed to MP4 via ComfyUI's
VideoInput.save_tointo a temp file, encoded, then cleaned up.
The result is a base64 string that can be large - the node helpfully logs the size in MB, and an honest warning is in order: a long clip becomes a very long string, and that string has to travel through the API request to BFL. Feed it into Flux 3 Video V2V's start_video socket and you're done. You can also take the output of a Flux 3 Video T2V/I2V/V2V node, run it through here, and chain it into another V2V pass - multi-shot continuation without ever touching disk.
Installing it
Same as the rest of the pack, once:
cd ComfyUI/custom_nodes
git clone https://github.com/gelasdev/ComfyUI-FLUX-BFL-API.git
cd ComfyUI-FLUX-BFL-API
pip install -r requirements.txt
Or just search "ComfyUI-FLUX-BFL-API" in ComfyUI Manager. The dependency list is torch plus what ComfyUI already ships - there's nothing heavy here, no model files. You don't even need an API key to use this node on its own, though you'll need one the moment you wire it into anything that actually calls BFL. The video type itself requires ComfyUI ≥ 0.3.30, same as the rest of the FLUX 3 video set.
The gotcha
It's just a conversion, so there's not much to break. The one thing to watch: the output is a string widget value, not a file - you can't preview it, and pasting a multi-megabyte blob into the V2V widget manually is a recipe for an unreadable workflow. Leave the wire connected and it's painless; break the link and you're back to hand-encoding. Also worth remembering if you're building a reusable workflow: base64 inflates the size by ~33% over the raw MP4, so keeping source clips short keeps your requests (and your BFL bills) sane.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| video | VIDEO | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | — |