PL Log inCreate account
Launching in October 2026. Accounts, model catalog, calculator and docs are live. Studio is available in preview; generation is awaiting activation.

Image xAI · 2026-01

Grok Imagine API

xAI image generation in standard or high quality, 1k or 2k, up to 4 per call

$0.0246per image

Failed generations are not charged. Prices exclude taxes. Billed from your prepaid USD balance.

Exact cost for your settings →

Examples

What Grok Imagine can do

Grok Imagine API, Quality Mode (high tier). Prompt: "Photo of a woman with friends at the pool, wide shot, the woman is wearing a swimsuit that's all yellow toned and a matching cover up, looking relaxed, natural skin and pores, skin imperfections, Italian leisure aesthetic, warm afternoon sunlight, high-contrast dappled canopy shadows, deep forest green, terracotta orange, crisp canvas white, herringbone brick textures, medium format editorial photography, analogue film warmth, architectural framing, tranquil luxury vibe, deep depth of field."
Grok Imagine API, Quality Mode (high tier). Prompt: "Photo of a woman with friends at the pool, wide shot, the woman…

Official examples from the model vendor: xAI.

Grok Imagine covers xAI's image models released in January 2026, offered at a flat per-image rate in two quality tiers, standard and high, picked with the quality field. One request returns up to 4 images in 13 aspect ratios plus auto, from 1:1 to tall 9:20 and wide 20:9, at 1k or 2k (a 16:9 image at 2k is 2816x1584). It can also edit a single source image. Prompts go up to 10,000 characters and are rendered as written.

Best for

  • Phone wallpapers and stories in tall 9:19.5 or 9:20 formats
  • Batches of up to 4 variations per prompt
  • Simple edits of one photo, such as restyling or adding an object
  • Draft rounds in standard quality before a final pass in high

Prompting tips

  • Explore with quality: standard, then switch to high for the images you will publish.
  • Match the ratio to the screen: 9:19.5 and 9:20 fit modern phones, 19.5:9 and 20:9 fit wide banners.
  • For edits, send exactly one image in image_urls and describe the change.
  • Your prompt is not rewritten, so spell out style and lighting yourself.

FAQ

How much does the Grok Imagine API cost?

Grok Imagine is billed at a flat rate per image, with a separate rate for each quality tier: $0.0246 per image. Failed generations are not charged.

What resolution does Grok Imagine output?

1k or 2k. At 2k, a 16:9 image comes out at 2816x1584.

Can Grok Imagine combine several reference images?

No, editing takes one source image. For multi-reference edits try Qwen Image 2.1 or Nano Banana 2.

How to call Grok Imagine via API

curl https://jantaris.com/v1/generate?wait=60 \
  -H "Authorization: Bearer $JANTARIS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "grok-imagine",
  "input": {
    "prompt": "Product photo of a matte black ceramic coffee cup on a travertine table, soft window light, 50mm",
    "aspect_ratio": "auto",
    "resolution": "1k"
  }
}'

Parameters

ParameterTypeAllowedDefault
prompt *string≤ 10000 chars
aspect_ratiostringauto 1:1 3:4 4:3 9:16 16:9 2:3 3:2 9:19.5 19.5:9 9:20 20:9 1:2 2:1auto
resolutionstring1k 2k1k
qualitystringstandard highstandard
num_imagesinteger1-41
image_urlsarraymax 1

The same schema is available from GET /v1/models/grok-imagine.