Apply Flux2 Fun ControlNet
How to use it in ComfyUI
- conditioning
- controlnet
- vae
- control_image
- mask
- inpaint_image
- CONDITIONING
What it does
This is the node that actually does something - it bends your text conditioning toward the spatial structure of a control image before the sampler sees it. Feed it a pose skeleton, a canny edge map, a depth image, or a few other supported types, and Flux 2 generates your prompt arranged the way your control image is arranged. The prompt decides what shows up; this node decides where.
It's built on Alibaba PAI's FLUX.2-dev-Fun-Controlnet-Union, a union checkpoint that auto-detects which of six control types you handed it (pose, canny, depth, HED, MLSD, or tile) rather than needing a separate model per mode. Worth knowing before you reach for this at all: instruction-editing models like Flux 2 Klein or Kontext will happily take a depth map as an input image and follow it from a sentence, which is simpler for a one-off edit. Where ControlNet wins is a strength dial - 40% of a pose instead of 100%, or two conditions stacked - because edit models don't give you that knob. This node is the strength-dial option.
Under the hood it's a monkey patch, not a from-scratch ComfyUI-core ControlNet: it injects control hints into Flux's double-stream transformer blocks (0, 2, 4, 6) through a 260-channel context (128 for the control image, 4 for the mask, 128 for optional inpainting). You don't need the internals to use the node, but it explains why this feels different from an SD-era ControlNet, which duplicated a chunk of a UNet that Flux 2 doesn't have - this hooks the attention layers instead.
Inputs and outputs that matter
Four required inputs, three optional:
- conditioning - text conditioning straight out of CLIP Text Encode. This node modifies it rather than replacing it.
- controlnet - plug in the output from Load Flux2 Fun ControlNet.
- vae - the Flux VAE. Required even though this node isn't decoding a final image; it's used to encode your control/inpaint images internally.
- strength - float, 0 to 2, default 0.75. The one dial you'll actually touch. For normal control mode, the README lands on 0.65–0.80 - in line with every other 2026-era union model (Flux 2, Z-Image, Qwen-Image), which all recommend lower strengths than the old SD-era default of 1.0.
- control_image (optional) - your pose/edge/depth guide image, auto-detected by type.
- mask + inpaint_image (optional, used together) - switches to an experimental "Control + Inpaint" mode for regional regeneration.
Output is a single conditioning (CONDITIONING) - wire it into your KSampler's positive conditioning input, same slot the unmodified conditioning would have gone into.
Setting it up
Two modes, two different strength ranges. For the normal case - pose, canny, depth, HED, MLSD, or tile - connect control_image, leave mask and inpaint_image disconnected, and set strength to 0.65–0.80, with 25–50 steps and CFG 3.5–4.5 per the README's recommendations. For the experimental Control + Inpaint mode, connect all three optional inputs - control_image as the structural guide, mask (white = area to regenerate), inpaint_image as the original - and drop strength to 0.25–0.40. Worth being upfront about what that mode actually is: mask-guided regional regeneration, not the context-aware inpainting you'd get from a dedicated model. If you need proper inpainting, reach for Flux Fill instead and treat this as a bonus, not the main event.
How to install it
Via ComfyUI Manager, search "comfyui-flux2fun-controlnet" and install. Or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/bryanmcguire/comfyui-flux2fun-controlnet.git
Restart ComfyUI afterward. You'll also need the checkpoint itself - FLUX.2-dev-Fun-Controlnet-Union.safetensors (~8.3GB) from Hugging Face - dropped in ComfyUI/models/controlnet/, plus a working Flux 2 setup: the Flux.2-dev base model and the Flux VAE. One licensing wrinkle: the node's own code is Apache 2.0, but the checkpoint carries Flux Dev's non-commercial license, which matters if you're planning to sell what you generate with it.
Common issues
Black output, or no visible effect. The README's own checklist is the right first pass: confirm strength is above 0, confirm vae is actually connected (easy to forget since this node doesn't look like it should need one), and confirm the control image loaded correctly rather than coming through blank or the wrong size.
Out of memory. Standard Flux-scale fixes: drop resolution, enable CPU offloading if available, close other GPU apps. Flux 2's stack is already heavy before you add a control pathway on top.
"Module not found" right after install. Restart ComfyUI - custom nodes are picked up at startup, not live.
A mystery timestep_zero_index crash on a Flux workflow that doesn't even use ControlNet. Thin evidence - one reported case on r/comfyui, not a widely-confirmed bug - but specific enough to mention: simply having this pack installed in custom_nodes was reported to break unrelated Flux (.1 or .2) workflows on ComfyUI 0.18.1, with none of its nodes even in the graph. A couple of other packs caused the same symptom before getting patched, so if you hit this on an unrelated workflow, temporarily pulling this pack out of custom_nodes is a cheap way to test.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| conditioning | CONDITIONING | — | |
| controlnet | FLUX2_FUN_CONTROLNET | — | |
| vae | VAE | — | |
| strength | FLOAT | 0.750–2 | — |
| control_imageopt | IMAGE | — | |
| maskopt | MASK | — | |
| inpaint_imageopt | IMAGE | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| CONDITIONING | CONDITIONING | — |