FLUX.1 Kontext in ComfyUI: Image Editing Guide

Quick start: Use a Kontext-compatible image-editing workflow, provide a source image and describe one change. Compare the result with the original; identity and background preservation are not guaranteed.

Before you begin: Confirm the exact model variant, its license, compatible nodes and model files. Use the official workflow for that variant rather than a generic FLUX text-to-image graph.



Illustration accompanying the FLUX Kontext editing guide

For two years, "editing" an AI image meant fighting with inpainting masks, ControlNet stacks, and prompt gymnastics just to change the color of a shirt. FLUX.1 Kontext changes the interaction model entirely: you give it an image and a plain-language instruction — "make the car red," "put the subject in a snowy forest," "remove the person on the left" — and it returns an edited image that keeps everything else consistent. No mask, no second model.

This post covers what Kontext is, how to wire it up in ComfyUI, and how to get reliable edits instead of full regenerations.

Visual guide: Check an edit against what must stay unchanged

Check an edit against what must stay unchangedKeep the source image then Define one requested change then Load the Kontext workflow then Compare source and edited crops then Accept or revise the edit. Editorial process diagram, not an execution screenshot.FLUXDRAW / VISUAL WORKFLOW1Keep the source image2Define one requested change3Load the Kontext workflow4Compare source and edited crops5Accept or revise the editExplanatory map / not a benchmark or test result
Original FluxDraw explanatory map. Follow the stages with the checks below; the map is not a screenshot, a measured result or an executable workflow.

How to use this map

  1. Save the source and list the features that should remain unchanged, such as identity, background layout or product shape. Keep the first requested edit narrow.
  2. Use the selected Kontext variant's input-image workflow. A generic FLUX text-to-image graph does not establish the same image-editing behavior.
  3. Describe the desired change directly, such as changing jacket color. Check the resulting image for collateral changes as well as the requested edit.
  4. Compare matched crops of faces, text and key objects. Save the instruction and configuration with rejected edits so later tuning addresses an observed failure.

Stop and check: A successful color change does not prove identity preservation. This diagram describes a review process, not a guaranteed editing result.

Next practical guides: Qwen-Image in ComfyUI: Setup and Text Rendering Checks · FLUX vs SDXL in ComfyUI: Test Plan and Comparison Scorecard

Implementation reference: FLUX.1 Kontext dev model card. Use the matching version-specific example alongside this editorial map.

Why Kontext Is Different

Illustration accompanying the FLUX Kontext editing guide


Kontext, from Black Forest Labs (the FLUX team), is an in-context image editing model. Instead of denoising from pure noise guided only by text, it conditions generation on an existing image plus an instruction, so it understands both "what is here" and "what should change."

The practical wins for developers and creators:

  • Character and product consistency across edits. You can iterate — edit the output, edit that output again — and the subject's identity holds far better than a text-to-image reroll.

  • Local, targeted changes without hand-painting a mask. The model infers the region from your instruction.

  • Style and relighting transforms ("make it look like a watercolor," "change to golden-hour lighting") that preserve composition.

The open-weights FLUX.1 Kontext [dev] variant is the one you run locally in ComfyUI; the hosted [pro]/[max] tiers live behind the BFL API. Check the license terms before commercial use — the [dev] weights ship under BFL's non-commercial community license.

Installing and Loading Kontext

  1. Update ComfyUI. Kontext support is native in current builds; older versions lack the reference-conditioning nodes.

  2. Download the weights. Place the Kontext [dev] diffusion model in ComfyUI/models/diffusion_models/. For 12–16 GB cards, grab the FP8 version; a GGUF quant exists for tighter budgets.

  3. Text encoders. Kontext uses the standard FLUX pair — clip_l and t5xxl (FP8 t5 is fine) — in ComfyUI/models/text_encoders/.

  4. VAE. The usual FLUX ae.safetensors in ComfyUI/models/vae/.

The quickest way in is the built-in template: Workflow > Browse Templates > FLUX Kontext.

The Node Graph

At its core the graph looks like a normal FLUX text-to-image workflow with one addition: your source image is encoded and injected as reference conditioning.

  1. Load Image > VAE Encode to turn your source into a latent reference.

  2. Load Diffusion Model (Kontext) + DualCLIPLoader (type flux) + VAE Loader.

  3. CLIP Text Encode holds your instruction, not a full description. Feed it into the reference-conditioning node (in current builds, a ReferenceLatent / Kontext conditioning node) alongside the encoded source image.

  4. KSampler > VAE Decode > Save Image.

Sampler Settings That Work

  • Steps: 20–28. Kontext is not a Turbo model; too few steps leave edits half-applied.

  • CFG / guidance: FLUX uses a distilled guidance value — start around 2.5–3.5. Higher pushes the edit harder but can drift from the source.

  • Sampler/scheduler: euler + simple or beta are reliable starting points.

  • Denoise: keep it at 1.0 — Kontext's consistency comes from reference conditioning, not from a partial-denoise trick. Lowering denoise here is a common mistake that weakens edits.

Writing Good Edit Instructions

Kontext rewards specific, single-change instructions and punishes vague ones.

  • Say what changes and what stays: "Change the jacket to bright yellow, keep the same pose and background."

  • One edit per pass. Chaining "make it night, add rain, and change her hair" produces compromises. Run three passes instead; each output feeds the next.

  • For text edits, quote the exact string: Replace the sign text with "OPEN 24/7".

  • To preserve identity, add "keep the same face and features" — it measurably reduces drift.

  • Avoid describing the whole scene from scratch; that nudges the model toward a regeneration rather than an edit.

Optimization Tips

  • VRAM: FP8 fits comfortably in 16 GB; the GGUF Q4/Q5 quants run on 8–12 GB with a modest quality cost. Add --lowvram if you hit OOM during VAE decode.

  • Speed: a FLUX Turbo/Hyper LoRA can cut steps to ~8 for quick previews — lock your composition on previews, then do a full-step final pass for clean edges.

  • Multi-reference: current Kontext workflows support chaining more than one reference image (e.g., a subject plus a style reference). Encode each and combine in the conditioning stage.

  • Batch consistency: fix the seed when producing a series so unrelated regions stay stable frame to frame.

Conclusion

Kontext collapses a whole category of masking-and-ControlNet busywork into a sentence. For product shots, character work, and rapid concept iteration it is the most practical open editing model available to run locally right now. Start with single, explicit instructions, keep denoise at 1.0, and treat editing as a chain of small passes rather than one big prompt — that is where the consistency that makes Kontext special actually shows up.



Downloadable Workflow & References