FLUX.2 hex color prompt: how to write it, with an API call

Black Forest Labs says FLUX.2 matches hex codes in prompts. The syntax it documents, the limits it admits, and a flux.2-pro call on Sume.

4 min readSume
All posts

Write the hex code next to the word "color" or "hex" and tie it to one named object: "the vase is the color #02eb3c". That is the syntax Black Forest Labs documents for FLUX.2, which it says supports precise color matching. On Sume you send that prompt to black-forest-labs/flux.2-pro through POST /v1/images.

The rules below come from BFL's hex color guide and FLUX.2 overview. The Sume side is from the Image API docs. All read 2026-09-29.

How do I write a hex color in a FLUX.2 prompt?

BFL's guide says to signal the color with a keyword such as "color" or "hex" followed by the code, and to associate each value clearly with a specific object or surface. It lists gradients too: name a start and an end color.

The overview page gives two examples. One prompt asks for a vase whose color is a gradient starting with color #02eb3c and finishing with color #edfa3c, with flowers in #ff0088. The other asks for an eyeshadow palette with six pans, each row listing its hex codes.

Hex-color prompting as Black Forest Labs documents it, read 2026-09-29. Source: BFL hex color guide.
DoAvoid
Signal the code with a keyword such as "color" or "hex" followed by the codeLeaving a code unassociated with any object or surface
Tie each code to one object: walls, sofa, vase"use #FF0000 somewhere", which BFL says may produce inconsistent results
Give a gradient a start and an end colorDescribing a gradient without naming its start and end colors

Can I send a hex color prompt through Sume?

Yes, as a normal image request to a model Sume lists. black-forest-labs/flux.2-pro is estimated at $0.04 per image on Sume. Sume's docs do not describe color-code prompting themselves, so the behavior is BFL's claim about FLUX.2, not a Sume feature. Test your brand colors before you rely on them.

curl -X POST https://api.sume.com/v1/images \
  -H "Authorization: Bearer $SUME_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "black-forest-labs/flux.2-pro",
    "prompt": "A vase on a table in a living room. The vase is a gradient of color, starting with color #02eb3c and finishing with color #edfa3c. The flowers inside have the color #ff0088.",
    "aspect_ratio": "4:5"
  }'

Does this work on other Sume image models?

BFL documents hex prompting for FLUX.2 only. This post makes no claim about any other model. If you want to try it elsewhere, run the same prompt and compare the colors with an eyedropper; do not assume it carries over.

How close will the color be?

BFL calls the results precise color matching but the guide gives no tolerance figure, and generated images add lighting and shading on top of a flat code. Sample the rendered pixel to see how far it landed. If the color must be exact, set it in your design tool after generation.

Because Sume's image URLs are signed, copy the files you keep into your own storage before you edit them.

Sources

Related posts

More in Models

All Models posts

Written by Sume