xAI · Grok Imagine image models
Grok Imagine API
xAI’s image generation and editing models, all on one key. The recommended Image 2.0 starts at $0.0179 / image on AnyAIGC, about 55% below xAI’s list price, and the first-gen Image is $0.0119. Unlimited concurrency.
- Models 3
- Price From $0.0119 / image
- Endpoints Generate · Edit
- Concurrency Unlimited
- Business Self-service invoices
Which Grok Image models are there
All three are live on AnyAIGC, billed per image. Switch by changing the model field.
- Recommended
Grok Imagine Image 2.0
grok-imagine-image-2.0xAI’s new model from August 2026, also the Quality mode on grok.com.
- Clean typography and small text
- One model for generation and editing
- 1k / 1.5k / 2k, low / medium quality
from $0.0179 / image
Grok Imagine Image
grok-imagine-imagexAI’s first-generation Imagine model, launched with the Imagine API in early 2026.
- Text to image
- 1k / 2k output
- Fine for existing code
$0.0119 / image
- Retired
Grok Imagine Image Quality
grok-imagine-image-qualityxAI’s high-quality mode from May 2026, merged into 2.0 on Nov 2.
- Served by 2.0 at low quality
- No code changes required
- Use 2.0 for new projects
from $0.0223 / image
What Grok Imagine can do
These samples were generated by Imagine Image 2.0 and come from xAI’s launch post.

Text and layout
Headlines, small print, schedules and captions are laid out the way a designer would, so dense posters, itineraries and infographics stay readable.

Precise edits
Change only what you ask for and keep the rest. Swap a background, recolor a product or remove clutter with one sentence.

Consistent style
Characters, locations and props generated separately keep the same look, which suits storyboards, picture books and game assets.

Many styles
Photoreal, ink wash, pixel art, manga and retro posters all come out reliably, with clear detail and texture.

15 aspect ratios
From 1:2 portrait to 21:9 widescreen. Pick a ratio and the model recomposes the scene instead of cropping it.

Product and marketing shots
Colorways, marketplace hero images and editorial product posters, ready to use from a single call.
One image, any aspect ratio
The model recomposes the same scene for each aspect ratio (xAI samples). Set it with the aspect_ratio parameter.

1:2 
9:16 
3:4 
1:1 
16:9 
2:1
- 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:1
- 21:9
- 5:2
- auto
Grok Imagine API pricing
Billed per image, from $0.0119 / image (Image) and $0.0179 / image (Image 2.0).
- Per imageBilled per generated image, not per token
- By resolution and quality2.0 and Quality are priced per tier
- EditsPlus $0.00447 per input image
- Unlimited concurrencyOn by default for everyone
| Resolution | Quality | AnyAIGC output | Edit input image | xAI list output |
|---|---|---|---|---|
Grok Imagine Image 2.0 (recommended) grok-imagine-image-2.0 | ||||
| 1K | Low | $0.0179 / image | $0.00447 / image | $0.04 / image |
| 1.5K | Low | $0.0223 / image | $0.00447 / image | $0.05 / image |
| 2K | Low | $0.0268 / image | $0.00447 / image | $0.06 / image |
| 1K | Medium | $0.0268 / image | $0.00447 / image | $0.06 / image |
| 1.5K | Medium | $0.0313 / image | $0.00447 / image | $0.07 / image |
| 2K | Medium | $0.0357 / image | $0.00447 / image | $0.08 / image |
Grok Imagine Image grok-imagine-image | ||||
| 1K / 2K | — | $0.0119 / image | No editing | $0.02 / image |
Grok Imagine Image Quality (retired by xAI) grok-imagine-image-quality | ||||
| 1K | — | $0.0223 / image | $0.00447 / image | Retired |
| 1.5K | — | $0.0268 / image | $0.00447 / image | Retired |
| 2K | — | $0.0313 / image | $0.00447 / image | Retired |
Prices from the AnyAIGC model catalog; edits on 2.0 and Quality add $0.00447 per input image. xAI list prices: 2.0 is $0.04–$0.08 / image depending on resolution and quality, plus $0.01 per input image; Image is $0.02 / image (xAI pricing). Billed per successful generation; live prices are in the model catalog.
Cost examples
Straight multiplication of the prices above, nothing else added.
-
1,000 first-gen images
1,000 × $0.0119
$11.90
Image
-
1,000 Image 2.0 images
1,000 × 1K Low $0.0179
$17.90
Image 2.0 · 1K Low
-
1,000 at 2K Medium
1,000 × 2K Medium $0.0357
$35.70
Image 2.0 · 2K Medium
Official Grok Imagine samples
These images were generated by Imagine Image 2.0 and come from xAI’s launch post.

TextureHalftone portrait rendered entirely in fine white dots 
Travel posterVintage travel poster of an Italian Riviera town 
InfographicIllustrated Odyssey infographic mapping the voyage home 
CinematicCinematic close-up glancing back across a candlelit ballroom 
MangaSoft manga page of a girl among cherry blossoms at dusk 
Ink washClassical Chinese ink painting of a waterfall and a robed figure 
Pixel artRetro pixel-art RPG title screen 
TypographyTypography history from movable type to digital fonts 
JournalHandwritten Odyssey journal with watercolor illustrations 
Product shotProduct shot of handwoven textiles stacked on a wooden table 
SurrealSurreal "World is so vast" travel poster with a whole world in a hat 
PosterGritty motivational poster of a sprinter in orange and black
Sample images come from xAI's Imagine Image 2.0 launch post, were generated by Imagine Image 2.0, and are copyrighted by xAI. View source
Grok Imagine API use cases
E-commerceProduct and lifestyle shots
Upload a product photo, change the background or color, and batch out hero images for different scenes.
MarketingPosters and ads
Put the headline, selling points and fine print right in the image for event posters, social posts and banners.
ContentInfographics and itineraries
Timelines, maps, schedules and tips on one page, made for travel guides, explainers and study cards.
GamesCharacters and worlds
Characters, locations and props keep one art style even when generated separately, ready for concept art.
PortraitsProfessional headshots
Turn one selfie into a clean, business-attire headshot for resumes and team pages.
DesignIcons and merch
Icons, stickers, T-shirt and mug mockups. Generate a first pass, then hand it to a designer.
Why call it through AnyAIGC
One key, 300+ models
Grok Imagine, GPT Image, Nano Banana and Seedream share one API key and one balance.
No xAI account needed
The endpoint
https://anyaigc.aineeds no xAI account.Fixed prices
A flat price per image, below xAI’s list price, with every charge visible in the console.
Unlimited concurrency
Every account runs without a concurrency cap, so batch jobs don’t wait for approval.
Get started with the Grok Imagine API
- Sign up for AnyAIGC. New accounts get 5M free tokens, and you can top up from $1.
- Create an API key in the console and save it as the
ANYAIGC_API_KEYenvironment variable. - Send a request to
POST https://anyaigc.ai/v1/images/generationswithmodelset togrok-imagine-image-2.0. For edits, usePOST /v1/images/edits.
import base64
import os
import requests
API_KEY = os.environ["ANYAIGC_API_KEY"]
resp = requests.post(
"https://anyaigc.ai/v1/images/generations",
headers={"Authorization": "Bearer " + API_KEY},
json={
"model": "grok-imagine-image-2.0",
"prompt": "A retro concert poster titled “Neon Night Drive”, bold vintage type, sharp small print “Dec 31, 2026 · Austin” at the bottom",
"aspect_ratio": "2:3", # 1:1, 16:9, 9:16, 3:2 and more
"resolution": "2k", # 1k / 1.5k / 2k
"quality": "medium", # low / medium / auto (2.0 only)
"n": 1,
"response_format": "b64_json", # or url
},
timeout=300,
)
resp.raise_for_status()
for i, item in enumerate(resp.json()["data"], 1):
if item.get("b64_json"):
with open(f"grok_{i}.jpg", "wb") as f:
f.write(base64.b64decode(item["b64_json"]))
print("saved", f"grok_{i}.jpg")
else: # with response_format url you get a temporary link, download it soon
print(item["url"])
curl https://anyaigc.ai/v1/images/generations \
-H "Authorization: Bearer $ANYAIGC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "grok-imagine-image-2.0",
"prompt": "A retro concert poster titled “Neon Night Drive”, bold vintage type, sharp small print “Dec 31, 2026 · Austin” at the bottom",
"aspect_ratio": "16:9",
"resolution": "1k",
"n": 1,
"response_format": "url"
}'
import os
import requests
# Image editing: upload the source image as multipart/form-data
API_KEY = os.environ["ANYAIGC_API_KEY"]
with open("photo.png", "rb") as img:
resp = requests.post(
"https://anyaigc.ai/v1/images/edits",
headers={"Authorization": "Bearer " + API_KEY},
files={"image": img},
data={"model": "grok-imagine-image-2.0", "prompt": "Replace the background with a snowy city street, keep the person and lighting unchanged", "n": 1},
timeout=300,
)
resp.raise_for_status()
print(resp.json()["data"][0])
Authenticate with Authorization: Bearer <API Key>. The response looks like {"created": ..., "data": [{"b64_json": ...}], "usage": {"generated_images": 1, ...}}; with response_format set to url you get a temporary link, so download it promptly. Field reference in the AnyAIGC docs: Create image, Edit image.
Grok Imagine API for teams and enterprises
E-commerce companies, design studios and content platforms can buy through a proper business process, with support for finance, legal and engineering.
- Invoices
Issue them yourself
Issue an invoice in the console for the amount you actually topped up, whenever you need one.
- Dedicated support
Account and technical contacts
Work with a dedicated support contact and technical engineer for onboarding, migration and troubleshooting.
- WeChat Pay
- Alipay
- USDT
- Credit card
Why teams trust AnyAIGC
Trial credit, top-ups, refunds, data handling and billing, spelled out up front.
5M free tokens to start
New accounts get trial credit, so you can test before you top up.
Top up from $1, refundable
Top up from $1. Unused balance can be refunded with no fee.
Official channels, real models
Requests go to official model channels, never cheaper or reverse-engineered substitutes.
No retention, no training
Unless the law requires it, your prompts and outputs are not persistently stored or used for training. See the privacy policy.
Transparent billing, spend caps
See tokens and cost for every request in the console, and set a quota on each API key.
24/7 support
Contact support any time about integration, billing or incidents.
Grok Image models
Same API key, same endpoint. Switch models by changing the model field.
Grok Imagine API FAQ
How much does the Grok Imagine API cost?
On AnyAIGC, Grok Imagine Image costs $0.0119 per image at 1k or 2k. Image 2.0 is priced by resolution and quality, from $0.0179 (1K Low) to $0.0357 (2K Medium) per image, and Quality from $0.0223 to $0.0313. Edits add $0.00447 per input image. Everything is billed per image, not per token. xAI’s list price is $0.04–$0.08 / image for 2.0 and $0.02 / image for Image. Live prices are in the model catalog.
Image 2.0, Image or Quality: which one should I use?
Grok Imagine Image 2.0 (grok-imagine-image-2.0) is the model xAI currently recommends, with stronger typography, prompt following and editing. It starts at $0.0179 / image on AnyAIGC, so start new projects here. Grok Imagine Image (grok-imagine-image) is the first-generation Imagine model at $0.0119 / image, the lowest price in the series, fine for plain text to image and existing code. Grok Imagine Image Quality was retired by xAI on Nov 2, 2026, and its requests are now served by 2.0 at low quality.
Has grok-imagine-image-quality been retired?
Yes. xAI retired grok-imagine-image-quality on Nov 2, 2026. Requests sent to that model name are now handled by grok-imagine-image-2.0 with quality: "low", and the request and response formats are unchanged. The model name still works on AnyAIGC from $0.0223 / image, but 2.0 at Low quality is $0.0044–$0.0045 cheaper per image at every resolution, so set model to grok-imagine-image-2.0.
Which aspect ratios and resolutions are supported?
Set aspect_ratio to 1:1, 3:4, 4:3, 9:16, 16:9, 2:3, 3:2, 1:2, 2:1, 21:9 and more, or auto to let the model decide. Use resolution for 1k, 1.5k or 2k (the first-gen Image supports 1k and 2k). Image 2.0 also supports quality (low / medium / auto).
Can I edit an image from a reference?
Image 2.0 supports editing: send the source image and your instruction to POST /v1/images/edits as multipart/form-data. xAI supports compositing up to 5 reference images per request; the AnyAIGC docs currently show a single-image example, so check the AnyAIGC API docs for multi-image input.
Do I need an xAI account?
No xAI account needed. Sign up on AnyAIGC to get an API key. The endpoint is https://anyaigc.ai, and the same key works with 300+ other models on the platform.
Is there a concurrency limit?
AnyAIGC sets no concurrency limit on the Grok Image models. Every account gets this by default, so batch jobs don’t need a quota request.
Can I get an invoice from AnyAIGC?
Yes. You can issue invoices yourself in the console, for the amount you actually topped up.
Which payment methods are supported?
You can top up with WeChat Pay, Alipay, USDT or a credit card. Your balance is in USD and works across every model on the platform. Invoices can be issued in the console for the amount you topped up.
Is there free trial credit for new users?
Yes. New accounts get 5 million tokens of trial credit, so you can test before deciding to top up. Top-ups start at $1.
Can I get a refund on my balance?
Yes. Unused balance can be refunded with no fee. Contact support to start a refund.
Are these the real models? Is my data safe?
Requests go to official model channels, never cheaper or reverse-engineered substitutes. Unless the law requires it, we do not persistently store your prompts or outputs or use them for training, and the console shows tokens and cost for every request.
Can I use the images commercially?
Usage rights and content policy follow xAI’s official terms. AnyAIGC only provides API access and adds no extra restrictions on what you do with the output.
Start building with Grok Imagine
Sign up and get 5M free tokens. From $0.0119 / image, unlimited concurrency.
