A frozen price list goes stale in a month. Here's how to measure the cost that actually hits your bill.

Search "cheapest image generation API" and you get a dozen ranked price lists, each with a different winner. They can all be right and all be useless to you, for two reasons. First, those numbers move — providers re-tier and re-price image models constantly, so a table that was accurate last month quietly lies today. Second, the sticker price on a single image is not what lands on your invoice. What lands is the cost of every image you generated to get the ones you kept.
So this guide hands you a method instead of a leaderboard: how to figure out which API is actually cheapest for your workload, in a way that survives the next price change. For any live HiAPI number, the pricing page is the source of truth — read the current number rather than trusting a copied one.
The headline rate every provider advertises is cost per generated image. The number that decides your budget is cost per usable image — one you'd actually put in front of a user. They are rarely the same.
The formula is simple:
cost per usable image = list price × attempts to an acceptable result
If a model lists cheap but you run it five times to get one frame you like, you paid the list price five times for one keeper. Industry write-ups that bother to measure this land in the same place: real cost per finished asset tends to run a multiple of the quoted per-image rate once retries and edit passes are counted. A model with a slightly higher sticker price that nails the brief on the first or second try is frequently the cheaper one in practice.
This is why a price list can't answer the question. "Attempts to an acceptable result" is a property of your prompts, quality bar, and subject matter — not something a table can know. Measure it on your own workload: generate a representative batch on two or three candidate models, count how many tries each needed to clear your bar, and multiply. The cheapest list price routinely loses this comparison.
When you do compare, these are the variables doing the work. Everything else is noise.
1. Resolution tier. Higher resolution costs more, often steeply. The mistake is generating every iteration at final resolution. You don't need 2K while you're still deciding on composition — you need it once, on the frame you're shipping. Draft small, finalize large.
2. Model class — lightweight vs flagship. There's a wide spread between fast, efficient models and top-tier flagships, and the gap is large enough to plan around. Lightweight models ("fast", "turbo", "schnell"-class) are built for speed and volume and cost a fraction of flagship rates. They are perfect for exploration, thumbnails, and anything where "good enough" is good enough. Flagships earn their price only on the final, customer-facing frame.
3. Per-image vs subscription billing. A flat monthly plan looks cheap on a slide but only beats per-image pricing past a high, steady monthly volume. And subscriptions usually assume a human at a seat — that model breaks the moment you're generating images on behalf of your own end users inside a product. For irregular or embedded workloads, pay-as-you-go is both cheaper and the only thing that fits.
4. The hidden costs. These are the line items the comparison tables skip:
Across teams that track them, these hidden costs add up to a meaningful slice of total image spend. They don't show up until the bill does.
Put the levers together and a concrete method falls out. The cheapest pipeline isn't "pick the cheapest model" — it's "spend cheap while you're searching, spend up only on what you ship."
The saving compounds because most of your attempts sit in step 1, where each image is cheapest, while the expensive rate only ever touches the small number of finals. That is structurally cheaper than running everything on one mid-tier model, and far cheaper than running everything on a flagship.
The workflow above needs two things from a provider: pay-as-you-go billing so you're not locked into a subscription that punishes irregular use, and access to both cheap and premium models through one integration so routing between them is trivial. HiAPI is built for exactly this.
model field — no second account, no second key, no second integration.The call shape is the same across models, so switching is genuinely just the model id:
# Draft pass: lightweight model, low resolution, run many variations
curl -X POST https://api.hiapi.ai/v1/tasks \
-H "Authorization: Bearer sk-<key>" \
-H "Content-Type: application/json" \
-d '{"model":"z-image","input":{"prompt":"<your prompt>","aspect_ratio":"1:1"}}'
# ...then poll GET /v1/tasks/<taskId> until status is "success",
# read data.output[0].url, and download promptly (the URL expires).
# Final pass: swap "model" to a flagship, raise resolution, run once on the keeper.
New accounts get currently $1 in free credit (around 50 images) — enough to actually run the draft-cheap, finalize-on-the-keeper experiment across a couple of models and measure your own cost per usable image before committing. Grab a key on the sign-up page and check live rates on the pricing page.
If you want a ranked opinion on which model produces the best output, that's our best image generation API roundup — it compares results, not cost. This guide is the cost lens, and the cheapest setup is usually a combination, not one "best value" pick: draft on the efficient model, finalize on the one the quality roundup likes.
Is there a truly free image generation API? There are free tiers and trial credits, and you can get quite far on them. We cover the genuinely free and no-key options separately in free AI image generation API, no key required. For paid usage, HiAPI's signup credit (currently $1, ~50 images) lets you measure real cost before you spend anything of your own.
What is the single cheapest image generation model (FLUX schnell, z-image, something else)? It depends, and it changes. Lightweight, efficient models like FLUX schnell and z-image sit at the cheap end and make good draft-phase choices, but the exact ranking moves with each price update — and the truly cheapest model for you also depends on attempts-to-acceptable for your prompts. Compare current rates on the pricing page and apply the method above; for a closer look at the efficient end, see our z-image pricing and examples writeup. Don't trust a fixed number in any article, including this one.
Why don't you just list the prices here? Because they'd be wrong by next month, and a stale number is worse than no number — it sends you into a decision on a price that no longer exists. The durable answer is a method plus a live pricing link.
Does pay-as-you-go ever lose to a subscription? Only at high, steady volume where an unlimited plan's flat fee beats your per-image total — and only when that plan's terms actually permit your use. For irregular workloads, or when you generate images on behalf of your own users, pay-as-you-go is both cheaper and the only model that fits.
Key Takeaways