Skip to main content
Edit images like magic. Describe what you want changed, and FLUX.2 makes it happen. Combine furniture from multiple photos into one room. Replace people with animals while keeping proportions perfect. Change backgrounds, swap textures, edit text—all while maintaining photorealism that matches professional photography. Reference multiple images simultaneously—up to 10 with [flex], up to 8 via API with [pro] (10 in playground). Create ad variants with consistent faces, build product mockups in any context, generate fashion editorials where models stay consistent across every scene.
Try it live - Upload images and describe your edits in our playground. See the magic happen in seconds.
Upgrading from FLUX.1? FLUX.2 adds multi-reference support, improved photorealism, better text editing, and output up to 4MP. See comparison →

See It In Action

These aren’t demos—they’re real edits you can make right now:
Multi-reference fashion editorial showing consistent characters across 10 scenes

8 images, one prompt: Create a complete fashion editorial with consistent characters across every scene

Prompt: Create a fashion editorial with consistent characters across multiple scenes
Interior design combining furniture and textures from multiple reference images

Combine furniture from multiple photos into one perfect room, apply textures from other images

Prompt: Use the empty illuminated concrete space from the first image as the room, place all the furniture from the images inside this space, and use the purple knit texture from the uploaded image to create a blanket draped over the red chair.
Scene with animals replacing people, maintaining natural proportions

Replace people with animals from 5 different images—proportions and scene composition stay perfect

Prompt: Replace the people in the image with the animals from images 2, 3, 4, 5, and 6. Adjust them to the space and style so they sit naturally in the scene. Adjust the proportions of the animals to each other and to the space
Color matching from reference

Create scenes using colors from reference images

Output with color-matched scene

Output with matched colors

How It Works

Multi-Reference Magic

Combine elements from multiple images into one perfect scene. FLUX.2 maintains consistency across characters, products, and styles—even when you’re mixing completely different sources. Limits vary by model: [pro] up to 8 via API (9MP total limit), [flex] up to 10. Example: Combine people and animals from separate photos Prompt: The person from image 1 is petting the cat from image 2, the bird from image 3 is next to them
Person reference

Reference 1: Person

Cat reference

Reference 2: Cat

Bird reference

Reference 3: Bird

Combined scene with person, cat, and bird

Result: All elements combined into one natural scene

Exact Color Control

FLUX.2 supports precise color matching using hex color codes. Specify exact brand colors without approximation, making it ideal for professional design workflows. Color Matching from Reference Images Reference a color from another image for precise matching: Prompt: Change the color of the gloves to the color of image 2
For best color matching performance, you can include a color square of the desired color in your reference images and disable Prompt Upsampling. FLUX.2 will match the exact color from the reference.
First reference image

Reference image 1

Second reference image

Color reference

Output image with gloves changed to the color of reference image 2

Output: The gloves are now the color of the reference image 2

Pose Guidance

Control exact positioning and body language. Upload a pose reference image and FLUX.2 matches it precisely—perfect for maintaining consistency across shots or recreating specific poses. Example: Match a pose from a reference image
Original input image

Input image

Pose guidance reference image

Pose guidance reference

Output with matched pose

Result: Exact pose match

Use pose guidance to:
  • Maintain consistent poses across multiple images
  • Recreate specific body positions from reference photos
  • Control character positioning in scenes
  • Match poses from sketches or wireframes

Extract & Recompose

Isolate products, objects, or elements from images and recompose them into new layouts. Perfect for creating product collages, marketing materials, and Instagram-ready content. Example: Extract products and create an Instagram ad collage Prompt: Extract the different products from this picture. Clean them up and create a collage from them like it would be for an ad on Instagram
Original product image

Input: Original product image

Product collage extracted and recomposed

Output: Clean product collage ready for Instagram

Use extraction to:
  • Create product showcases from lifestyle photos
  • Build marketing collages from product shots
  • Isolate elements for social media content
  • Clean up and recompose product catalogs

Advanced Multi-Reference Techniques

Collage Method
Quality may be slightly lower with the collage method compared to using multiple separate input images. For best results, use individual reference images when possible.
You can also use a single input image containing a collage layout to guide composition. This method is useful for quick layout experiments. Prompt: Create a cinematic street scene in front of the pastel-colored corner building. The man in the dark suit is leaning against the wall near the café entrance. The woman is walking past him, carrying one of the Azzedine Alaïa tote bags. The focus is on their contrasting styles — her relaxed, creative vibe versus his confident, formal look. The black boots are part of her outfit
Collage input with building, people, and accessories

Input: Collage with reference elements

Cinematic street scene composed from collage elements

Output: Composed scene from collage elements

Using FLUX.2 API for Image Editing

FLUX.2 image editing requires both a text prompt and an input image to work. The input image serves as the base that will be edited according to your prompt. You can optionally include additional reference images for multi-reference editing:
  • [pro]: Up to 8 reference images via API (9MP total limit), up to 10 in playground
  • [flex]: Up to 10 reference images (API and playground)
  • [dev]: Recommended max 6 reference images (open model, limited by memory)
To use FLUX.2 for image editing, you’ll make a request to either the /v1/flux-2-pro or /v1/flux-2-flex endpoint:

Create Request

# Using image URLs (simplest method)
request=$(curl -X POST \
  'https://api.bfl.ai/v1/flux-2-pro' \
  -H 'accept: application/json' \
  -H "x-key: ${BFL_API_KEY}" \
  -H 'Content-Type: application/json' \
  -d '{
    "prompt": "<What you want to edit on the image>",
    "input_image": "https://example.com/your-image.jpg",
    "input_image_2": "https://example.com/reference-2.jpg"
  }')
echo $request
request_id=$(echo $request | jq -r .id)
polling_url=$(echo $request | jq -r .polling_url)
A successful response will be a JSON object containing the request’s id, polling_url, and pricing information:
Response Example
{
  "id": "task-id-here",
  "polling_url": "https://api.bfl.ai/v1/get_result?id=task-id-here",
  "cost": 4.5,           // Credits charged for this request
  "input_mp": 2.07,      // Input megapixels
  "output_mp": 2.07      // Output megapixels
}
The cost field shows the credits charged for the request. Use this to track pricing for your image editing operations.

Poll for Result

After submitting a request, you need to poll using the returned polling_url to retrieve the output when ready.
while true; do
  sleep 0.5
  result=$(curl -s -X 'GET' \
    "${polling_url}" \
    -H 'accept: application/json' \
    -H "x-key: ${BFL_API_KEY}")
  
  status=$(echo $result | jq -r .status)
  echo "Status: $status"
  
  if [ "$status" == "Ready" ]; then
    echo "Result: $(echo $result | jq -r .result.sample)"
    break
  elif [ "$status" == "Error" ] || [ "$status" == "Failed" ]; then
    echo "Generation failed: $result"
    break
  fi
done
A successful response will be a JSON object containing the result, and result['sample'] is a signed URL for retrieval.
Our signed URLs are only valid for 10 minutes. Please retrieve your result within this timeframe.

FLUX.2 Image Editing Parameters

For image editing, FLUX.2 matches input image dimensions by default (rounded to multiples of 16). Use width and height to override.Resolution:
  • Minimum: 64x64
  • Maximum: 4MP (e.g., 2048x2048)
  • Recommended: Up to 2MP
  • Output: Always multiples of 16
Input image preprocessing: FLUX.2 automatically preprocesses input images to meet resolution requirements:
  • Images over 4MP are resized to 4MP while preserving the aspect ratio (dimensions rounded to multiples of 16 pixels)
  • Non-aligned dimensions are cropped to the next smaller multiple of 16 pixels on each edge
This means your input image may be slightly modified before processing. If pixel-perfect alignment matters for your use case, ensure your input images are already at 4MP or below with dimensions that are multiples of 16.
List of FLUX.2 parameters for image editing via the /v1/flux-2-pro and /v1/flux-2-flex endpoints:
ParameterTypeDefaultDescriptionRequired
promptstringText description of the edit to be applied. Supports up to 32K tokens for long-form prompts.Yes
input_imagestringBase64 encoded image or URL of image to use as reference. Supports up to 20MB or 20 megapixels. Input resolution: minimum 64x64, recommended up to 2MP, maximum 4MP (e.g., 2048x2048). Dimensions must be multiples of 16.Yes
input_image_2 through input_image_9stringnullAdditional reference images for multi-reference editing. Each parameter accepts base64 encoded image or URL. [pro]: Up to 7 additional images (8 total, 9MP limit). [flex]: Up to 9 additional images (10 total). [dev]: Recommended max 5 additional images (6 total).No
widthinteger / nullnullOutput width in pixels. Must be a multiple of 16. If omitted, matches input image width.No
heightinteger / nullnullOutput height in pixels. Must be a multiple of 16. If omitted, matches input image height.No
seedinteger / nullnullSeed for reproducibility. If null or omitted, a random seed is used. Accepts any integer.No
safety_toleranceinteger2Moderation level for inputs and outputs. Value ranges from 0 (most strict) to 6 (more permissive).No
output_formatstring"jpeg"Desired format of the output image. Can be “jpeg” or “png”.No
guidancenumber / null4.5[flex only] Guidance scale for generation. Controls how closely the output follows the prompt. Minimum: 1.5, maximum: 10, default: 4.5.No
stepsinteger / null50[flex only] Number of inference steps. Maximum: 50, default: 50.No
webhook_urlstring / nullnullURL for asynchronous completion notification. Must be a valid HTTP/HTTPS URL.No
webhook_secretstring / nullnullSecret for webhook signature verification, sent in the X-Webhook-Secret header.No

Multi-Reference Editing

When using multiple input_image parameters (input_image, input_image_2, input_image_3, etc.), FLUX.2 combines elements from multiple source images while maintaining consistency. This is particularly useful for:
  • Character consistency: Maintain the same character across different scenes
  • Product mockups: Use product reference images in various contexts
  • Style transfer: Combine style references with content images
  • Fashion editorials: Keep models and clothing consistent across variations
FLUX.2 understands your input images, making it possible to describe what you want to change using natural language. You can reference specific images by index number or describe elements from your input images. Example 1: Natural Language Descriptions Describe elements from your input images naturally, and FLUX.2 understands them: Prompt: The man is leaning against the wall reading a newspaper with the title "FLUX.2". The woman is walking past him, carrying one of the tote bags and wearing the black boots. The focus is on their contrasting styles — her relaxed, creative vibe versus his formal look.
FLUX.2 intelligently identifies elements across multiple input images based on your descriptions, even when you don’t specify exact image indices.
Example 2: Explicit Image Indexing Reference specific images by number for precise control: Prompt: Replace the top of the person from image 1 with the one from image 2 This approach gives you explicit control over which elements come from which reference image. Example 3: Combining Multiple People Combine people from different images into a single scene: Prompt: This exact image but the couple next to the fire replaced by the people in image 2 and 3 API Example: Multi-reference editing with multiple input images
Multi-Reference Editing Example
import requests
import os

api_key = os.environ.get("BFL_API_KEY")

response = requests.post(
    'https://api.bfl.ai/v1/flux-2-pro',
    headers={"x-key": api_key},
    json={
        "prompt": "The person from image 1 is petting the cat from image 2, the bird from image 3 is next to them",
        "input_image": "https://example.com/person.jpg",      # URL or base64
        "input_image_2": "https://example.com/cat.jpg",       # URL or base64
        "input_image_3": "https://example.com/bird.jpg",      # URL or base64
        "seed": 42,
        "output_format": "jpeg"
    }
)

request_id = response.json()["id"]
Use input_image for the main image, and input_image_2 through input_image_9 for additional reference images. Limits vary by model: [pro] up to 8 total (9MP hard limit), [flex] up to 10 total, [dev] recommended max 6 total.

Choosing Between [pro] and [flex]

[pro][flex]
Best forProduction workflowsMaximum quality
Speed< 10 secondsHigher latency
Reference imagesUp to 8 (API, 9MP limit), 10 (playground)Up to 10
ControlsStandardAdjustable steps & guidance
Pricing$0.045 / edit$0.12 / edit

FLUX.2 [pro]

Fast & EfficientBest balance of speed and quality. Ideal for high-volume editing workflows.

FLUX.2 [flex]

Maximum QualityBest multi-reference accuracy and detail preservation. Use when quality is priority.

What’s Better Than FLUX.1

CapabilityFLUX.1FLUX.2
Multi-reference images1 image[pro]: Up to 8 (API), 10 (playground)
[flex]: Up to 10
[dev]: Recommended max 6
Output resolutionUp to 1.6MP (except [ultra])Up to 4MP
Text editingBasicImproved accuracy
PhotorealismGoodHigher fidelity on skin, hair, fabric, hands
Prompt followingStandardEnhanced complex instruction handling
World knowledgeLimitedMore grounded in lighting and spatial logic