> ## Documentation Index
> Fetch the complete documentation index at: https://docs.comfy.org/llms.txt
> Use this file to discover all available pages before exploring further.

# ZImageFunControlnet - ComfyUI Built-in Node Documentation

> ZImageFunControlnet applies a control network patch to a base model so it can guide the image generation or editing process.

ZImageFunControlnet applies a control network patch to a base model so it can guide the image generation or editing process. It combines a model, a model patch, and a VAE, and lets you control how strongly the control effect influences the result. Optional image, inpainting image, and mask inputs allow more targeted edits. The node works with Z-Image ControlNet patches and with Qwen Image 2.1 Fun ControlNet patches loaded through the Load Model Patch node.

## Inputs

| Parameter | Description | Data Type | Required | Range |
| - | - | - | - | - |
| `model` | The base model used for the generation process. | MODEL | Yes | - |
| `model_patch` | A specialized patch model that applies the control network's guidance. | MODEL\_PATCH | Yes | - |
| `vae` | The Variational Autoencoder used for encoding and decoding images. | VAE | Yes | - |
| `strength` | The strength of the control network's influence. Positive values apply the effect, while negative values can invert it (default: 1.0). | FLOAT | Yes | -10.0 to 10.0 (step 0.01) |
| `image` | An optional base image to guide the generation process. | IMAGE | No | - |
| `inpaint_image` | An optional image used specifically for inpainting areas defined by a mask. | IMAGE | No | - |
| `mask` | An optional mask that defines which areas of an image should be edited or inpainted. | MASK | No | - |
| `start_percent` | The point in the denoising process, as a fraction of the total sampling steps, where the control network starts taking effect (default: 0.0). | FLOAT | No | 0.0 to 1.0 (step 0.001) |
| `end_percent` | The point in the denoising process where the control network stops taking effect (default: 1.0). | FLOAT | No | 0.0 to 1.0 (step 0.001) |

**Note:** The `inpaint_image` parameter is typically used in conjunction with a `mask` to specify the content for inpainting. The node's behavior may change based on which optional inputs are provided (e.g., using `image` for guidance or using `image`, `mask`, and `inpaint_image` for inpainting). The `start_percent` and `end_percent` values restrict the control network to a window of the denoising process, and outside that window the model is sampled without the patch. If `strength` is 0, or if none of `image`, `inpaint_image`, and `mask` is connected, the node returns the base model unchanged. For Z-Image Control patches a provided mask is inverted (1.0 - mask) before use, while a Qwen Image 2.1 Fun ControlNet patch uses the mask as given. This node is flagged as experimental.

## Outputs

| Output Name | Description | Data Type |
| - | - | - |
| `model` | The model with the control network patch applied, ready for use in a sampling pipeline. | MODEL |

> This documentation was AI-generated. If you find any errors or have suggestions for improvement, please feel free to contribute! [Edit on GitHub](https://github.com/Comfy-Org/embedded-docs/blob/main/comfyui_embedded_docs/docs/ZImageFunControlnet/en.md)

***

**Source fingerprint (SHA-256):** `9673b8b6e091713bcc93fe5fd1cfed12e6941571d1017e10ac94c19e1afd4ca1`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.