Skip to main content

Black Forest Labs FLUX.2 [klein]

The fastest model in the FLUX.2 family, optimized for sub-second image generation with support for up to 4 reference images.
FLUX.2 Klein is a high-speed text-to-image API that generates quality images in sub-second time. Developed by Black Forest Labs, it supports up to 4 reference images for style and subject transfer, making it ideal for real-time applications and high-volume generation workflows. The model produces images in multiple aspect ratios at 1k or 2k resolution in both PNG and JPEG formats.

Key capabilities

  • Sub-second generation: Fastest model in the FLUX.2 family for real-time applications
  • Multi-image reference: Up to 4 reference images (input_image, input_image_2, input_image_3, input_image_4) for style/subject transfer
  • Flexible aspect ratios: 10 preset ratios including square, widescreen, portrait, and social media formats
  • Resolution options: Choose between 1k (standard) or 2k (high resolution, capped at 2048px)
  • Safety control: Adjustable tolerance level from 0 (most strict) to 5 (least strict)
  • Output formats: PNG (lossless) or JPEG (compressed)
  • Async processing: Webhook notifications or polling for task completion

Use cases

  • Real-time applications: Chatbots and interactive tools requiring instant image generation
  • Style transfer: Apply visual styles from reference images to new generations
  • High-volume workflows: Generate thousands of images efficiently
  • Rapid prototyping: Quick iteration on creative concepts and designs
  • E-commerce: Generate product variations and lifestyle imagery at scale

Generate images with FLUX.2 Klein

Create images by submitting a request to the API. The service returns a task ID for async polling or webhook notification.

Parameters

ParameterTypeRequiredDefaultDescription
promptstringYes-Text description of the image to generate
aspect_ratiostringNosquare_1_1Image aspect ratio (see table below)
resolutionstringNo1kResolution: 1k (standard) or 2k (high resolution)
seedintegerNorandomSeed for reproducible generation (0-4,294,967,295)
input_imagestringNo-Base64-encoded reference image for style transfer
input_image_2stringNo-Second reference image
input_image_3stringNo-Third reference image
input_image_4stringNo-Fourth reference image
safety_toleranceintegerNo2Content moderation: 0 (strict) to 5 (lenient)
output_formatstringNo-Output format: png or jpeg
webhook_urlstringNo-URL for completion notification

Aspect ratios

Aspect RatioBase Dimensions (1k)
square_1_11024 × 1024
widescreen_16_91344 × 768
social_story_9_16768 × 1344
portrait_2_3832 × 1216
traditional_3_4960 × 1280
vertical_1_2704 × 1408
horizontal_2_11408 × 704
social_post_4_5896 × 1152
standard_3_21216 × 832
classic_4_31280 × 960

Frequently Asked Questions

FLUX.2 Klein is the fastest model in the FLUX.2 family by Black Forest Labs, optimized for sub-second image generation. You submit a text prompt via the API, optionally include up to 4 reference images, receive a task ID immediately, then poll for results or receive a webhook notification when processing completes.
You can provide up to 4 Base64-encoded reference images using input_image, input_image_2, input_image_3, and input_image_4 parameters. The model uses these images to guide style, composition, and subject elements in the generated output while still following your text prompt.
FLUX.2 Klein uses preset aspect ratios (square_1_1, widescreen_16_9, portrait_2_3, etc.) combined with resolution settings (1k or 2k). The 2k resolution doubles the base dimensions but caps at 2048px per side.
FLUX.2 Klein is the fastest model in the FLUX.2 family, achieving sub-second generation times. This makes it ideal for real-time applications where speed is critical, though FLUX.2 Pro offers higher quality for less time-sensitive use cases.
See Rate Limits for current limits by subscription tier.
See Pricing for detailed rates and free tier credits.
FLUX.2 Klein is optimized for speed with sub-second generation, ideal for real-time applications. FLUX.2 Pro offers higher quality output for premium results. Choose FLUX.2 Klein when speed is critical; choose FLUX.2 Pro when quality is the priority.

Best practices

  • Reference images: Use high-quality reference images with clear style elements for best transfer results
  • Prompt writing: Be specific about subjects, scenes, and visual details even when using reference images
  • Aspect ratio selection: Choose the appropriate preset aspect ratio for your use case
  • Resolution choice: Use 1k for speed, 2k for higher detail (capped at 2048px)
  • Production integration: Use webhooks instead of polling for scalable applications
  • Error handling: Implement retry logic with exponential backoff for 503 errors