Skip to main content
Black Forest LabsMediumUltra

FLUX Kontext Max

A premium text-based image editing model that delivers maximum performance and improved typography generation for transforming images through natural language prompts.

190 credits
per image
Top-tier Kontext editing performance, above FLUX Kontext Pro
Improved typography and text rendering in edited images
Natural language instruction-based editing
Aspect ratio auto-match to the input image
Consistent character and style preservation across edits

Run it right now

Test this model instantly in the Console Playground โ€” no code required

Sign in to try

Use with AI Assistant

Copy usage instructions for Claude, ChatGPT, or other AI

Quick Start

curl -X POST "https://api.core.today/v1/predictions" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: cdt_your_api_key" \
  -d '{
  "model": "black-forest-labs/flux-kontext-max",
  "input": {
    "prompt": "Make the letters 3D, floating in space on a city street",
    "input_image": "https://replicate.delivery/xezq/XfwWjHJ7HfrmXE6ukuLVEpXWfeQ3PQeRI5mApuLXRxST7XMmC/tmpc91tlq20.png",
    "aspect_ratio": "match_input_image"
  }
}'

Parameters

ParameterTypeRequiredDefaultDescription
promptstringYes-Text description of what you want to generate, or the instruction on how to edit the given image
input_imagestringNo-Image to use as reference. Must be jpeg, png, gif, or webp
aspect_ratiostringNomatch_input_imageAspect ratio of the generated image. match_input_image matches the input image's ratio
match_input_image1:116:99:164:33:43:22:34:55:421:99:212:11:2
output_formatstringNopngOutput format for the generated image
jpgpng
safety_toleranceintegerNo2Safety tolerance, 0 is most strict and 6 is most permissive. Max 2 when input images are used
prompt_upsamplingbooleanNofalseAutomatic prompt improvement
seedintegerNo-Random seed. Set for reproducible generation

How to Provide File Input

There are 3 ways to provide files for the input_image parameter:

Recommended

Direct Upload (Multipart)

Attach files directly to POST /v1/predictions/upload. No separate upload step needed.

curl -X POST "https://api.core.today/v1/predictions/upload" \
  -H "X-API-Key: cdt_your_api_key" \
  -F "model=black-forest-labs/flux-kontext-max" \
  -F 'input={"prompt":"your prompt here"}' \
  -F "file:input_image=@your_file.png"

Image URL

Pass a publicly accessible URL directly. You can also use file_url from the Storage API.

{
  "model": "black-forest-labs/flux-kontext-max",
  "input": {
    "prompt": "your prompt here",
    "input_image": "https://example.com/image.jpg"
  }
}
See the File Upload docs for more upload methods including Presigned URLs.

Common Parameters

Common parameters used when calling POST /v1/predictions.

ParameterTypeRequiredDefaultDescription
modelstringYes-Model identifier
inputobjectYes-Object containing the model-specific parameters from the table above
output_folderstringNo-Folder path for output files (max 256 chars, '..' not allowed)
webhook_urlstringNo-Webhook URL to call on completion
is_publicbooleanNofalseIf true, output files are also available via permanent public URLs

Examples

3D Typography Edit

Transform 2D text in a photo into a floating 3D effect

curl -X POST "https://api.core.today/v1/predictions" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: cdt_your_api_key" \
  -d '{
  "model": "black-forest-labs/flux-kontext-max",
  "input": {
    "prompt": "Make the letters 3D, floating in space on a city street",
    "input_image": "https://replicate.delivery/xezq/XfwWjHJ7HfrmXE6ukuLVEpXWfeQ3PQeRI5mApuLXRxST7XMmC/tmpc91tlq20.png",
    "aspect_ratio": "match_input_image"
  }
}'

Tips & Best Practices

1This is the top-tier Kontext model โ€” use FLUX Kontext Pro first and reserve Max for edits that need the best typography and instruction fidelity
2safety_tolerance is capped at 2 whenever an input_image is supplied
3prompt_upsampling can improve results for short or vague editing instructions
4Use match_input_image (default) to preserve the source image's framing

Use Cases

Premium brand asset editing requiring precise typography
Complex multi-step image transformations via natural language
Style transfer and background changes for hero imagery
High-stakes creative work where Kontext Pro quality is insufficient

Model Info

ProviderBlack Forest Labs
Version-
CategoryImage Generation
Price190 credits

API Endpoint

POST /v1/predictions
Try in ConsoleBack to Docs