我们通过 一个 API 路由了 52 个图像生成模型。我们用同一个提示词跑通了其中 20 个,并记录了每次调用计费了多少、返回了什么,以及它接受什么输入。
成本是最棘手的部分,因为这些模型并非按同一单位计价。FLUX.2 按每兆像素计价。Gemini、OpenAI 和 Microsoft MAI 按 token 计价。Grok、Recraft、Riverflow、Qwen 和 Seedream 按每张图像计价,费率会随你所要求的质量和分辨率而变化。每个模型页面以其自身单位来看都是正确的,所以你无法通过并排阅读它们的价格来比较其中两个。
我们把它们放在同一基准上。我们测试的这 20 个模型都收到了相同尺寸的同一提示词,我们从每个响应中读取了 usage.cost 字段,也就是我们实际收取的金额。
本页面上的每一个价格都来自一次真实生成,测量于 2026 年 9 月 11 日。价格和模型经常变化,所以任何超过一个月的数据都应视为参考提示,而非预算条目。你可以用
GET /api/v1/images/models重新拉取当前接受的参数,用GET /api/v1/images/models/{model}/endpoints重新拉取标注了单位的定价。
总结
- 从 openai/gpt-image-2 开始。它在短提示词上计费 $0.006,在较长提示词上计费 $0.0135,这使它成为我们测量到的最便宜的模型,而且它正确地渲染了我们的两行标签和参考编辑。
- 如果图像很难做对,可以进一步选择 sourceful/riverflow-v2.5-pro,价格为 $0.064;如果回复既需要文字也需要图片,可以选择 google/gemini-3-pro-image,价格为 $0.134;如果你需要的是可编辑的 SVG 而不是像素图,可以选择 recraft/recraft-v4.1-vector,价格为 $0.08。
- 在我们测量的 20 个模型中,默认设置下生成一张图片的计费在 $0.006 到 $0.134 之间,相差 22 倍。
- 每个模型页面都用自己的单位标价,而实际计费成本可能与标价不同。比较两个模型的方法是:各生成一张图片,然后从响应中读取
usage.cost。 - 在 OpenAI 模型上,
quality设置让同一张图片从 $0.006 变为 $0.211。 n,即一次调用返回的图片数量,在 FLUX.2、Gemini、Grok、Riverflow 和 MAI 上上限为 1。seed在 Gemini、Grok、OpenAI、Riverflow、Recraft 或 MAI 上不存在。在 FLUX.2 Klein 上存在该设置时,相同的 seed 逐字节复现了同一张图片。- 我们要求生成可读文本的六个模型中,有五个正确渲染了文本,包括最便宜的那个。
- 原始 API 返回
data[0].b64_json。TypeScript SDK 返回data[0].b64Json。
每个模型向我们收取的费用
我们向这 20 个模型分别发送了提示词“A studio packshot of a glass bottle, hard key light, no text.”,使用 aspect_ratio: "1:1" 且未设置其他参数,然后从响应中读取 usage.cost。计费单位一列是每个端点定价记录中的 unit 字段。

图 1. 相同的价格,经过排序。三种计费单位在整个区间内一路混杂,因此单位并不能告诉你一个模型落在区间中的哪个位置。
在根据这张表制定预算之前,你需要了解三件事。
- 当我们未设置
resolution时,两个 Seedream 模型都返回了 2048x2048,而不是 1024x1024。Seedream 5.0 Lite 将2K列为它接受的最低分辨率。Seedream 5.0 Pro 接受1K,但其默认调用返回了 2K,并按 $0.09 的高分辨率费率计费,而不是 $0.045 的基础费率。Seedream 5.0 Lite 以 $0.035 的价格给你四百万像素,因此按每像素计算,它比表格看起来的要便宜。 - FLUX.2、Grok 和 Seedream 返回了 JPEG。OpenAI、Qwen、Microsoft 和 Krea 返回了 PNG。Sourceful 和 Recraft 返回了 WebP,而 Recraft 的矢量模型返回了 SVG。我们测试的三个 Gemini 模型不接受
output_format,而且它们返回的格式并不全都相同,所以不要硬编码文件扩展名。在接受该参数的十二个目录模型上设置output_format。在不接受该参数的模型上,读取每个响应都会返回的media_type字段。 - 两次使用相同请求体调用
sourceful/riverflow-v2.5-fast,分别计费 $0.017623 和 $0.017639。请根据多次调用的平均值来制定预算,而不是根据单次调用。
质量设置会让价格变动 35 倍
在 OpenAI 模型上,quality 对你的账单的影响比任何其他设置都大。我们用相同的提示词、相同的 1024x1024 尺寸运行了 gpt-image-2,分别将 quality 保持未设置、设置为 low 以及设置为 high。
| 质量 | 图像 token | 计费 |
|---|---|---|
| 未设置 | 196 | $0.00599 |
| 低 | 196 | $0.00599 |
| 高 | 7,024 | $0.21083 |
将 quality 保持未设置,得到的 token 数量和账单与 low 相同。当图像质量很重要时,请显式设置 quality;对于 OpenAI 模型的单张图像价格,除非它明确标注了质量档位,否则应视为不完整。high 调用还耗时 123 秒才返回,而默认调用仅需 12 秒。
宽高比对账单的影响要小得多
在按每兆像素计费的模型上,你请求的画面尺寸会改变账单,但变化幅度小于像素数量所暗示的程度。我们用 black-forest-labs/flux.2-klein-4b 跑了两种形状。21:9 的调用返回 2400x1024,即 2.46 兆像素,而正方形为 1.05 兆像素。正方形计费 $0.014,宽幅裁剪计费 $0.016。
标价与实际计费可能不同
每个模型都会在其页面上以及 API 的端点路由中公布一个费率。这些费率只是一个用于规划的参考数字,实际响应结果才是你最终支付的费用。2026 年 9 月 11 日,sourceful/riverflow-v2.5-pro 在其默认分辨率下列出的价格为每张图片 $0.13,而实际向我们计费 $0.064。black-forest-labs/flux.2-flex 列出的是每百万像素 $0.06,而对一张一百万像素的图片向我们计费 $0.05。black-forest-labs/flux.2-max 列出的是 $0.07,并恰好向我们计费 $0.07。krea/krea-2-medium 在其端点上没有公布任何定价记录,并向我们计费 $0.03。
当两者不一致时,请查看 usage.cost,而不是用列出的费率乘以估算值。
对于已完成的图片请求,我们全额计费;对于失败的请求,我们不收取任何费用。Image API 计费文档 说明了哪些结果会被计费。
参考资料、格式与限制
价格只是一个维度。以下是其他维度,其中有两个维度在成本成为考虑因素之前就已经将某些模型排除在外。这些数值来自 2026 年 9 月 11 日各端点的 supported_parameters。
| 系列 | 输出模态 | 最大参考图片数 | output_format | 每次调用的图片数(n) | seed |
|---|---|---|---|---|---|
| FLUX.2 Klein | 图像 | 4 | png、jpeg | 1 | 是 |
| FLUX.2 Flex、Pro、Max | 图像 | 8 | png、jpeg | 1 | 是 |
| Gemini 3.x 图像 | 图像、文本 | 14 | 不可设置 | 1 | 否 |
| Grok Imagine Image | 图像 | 3 | 不可设置 | 1 | 否 |
| OpenAI gpt-image | 图像 | 16 | 不可设置 | 1 到 10 | 否 |
| OpenAI gpt-5-image | 图像、文本 | 16 | 不可设置 | 1 到 10 | 否 |
| Seedream 5.0 | 图像 | 14 | 不可设置 | Lite 上为 1 到 4,Pro 上为 1 | 是 |
| Recraft v4.1 | 图像 | 1 | 矢量模型上的 svg | 1 到 6 | 否 |
| Qwen Image 3 | 图像 | 4 | 不可设置 | 1 到 6 | 是 |
| Riverflow 2.5 | 图像 | Fast 上为 4,Pro 上为 10 | Fast 上为 jpeg,Pro 上为 png、jpeg、webp | 1 | 否 |
| Microsoft MAI Image 2.5 | 图像 | 1 | 不可设置 | 1 | 否 |
| Krea 2 Medium | 图像 | 1 | 不可设置 | n 未公布 | 是 |
参考图像是你在请求中随附、供模型据此工作的图像,既可以是你希望编辑的图像,也可以是希望模型匹配的风格或产品示例。可发送数量的上限是硬性上限。Grok 接受三张,Gemini 接受十四张,因此一套六张图的品牌素材包在还没比较其他任何东西之前就已经把 Grok 排除在外了。
输出模态这一列是第二个维度。这些模型大多接受文本和图像输入,只返回图像字节。Gemini 图像模型和 OpenAI 的 gpt-5-image 模型还能在同一次回复中返回书面文本,如果你想让模型解释它生成了什么,这一点很重要。我们在下文进一步测试了它们这样做的可靠性。
对任何带有
GET /api/v1/images/models的模型重新拉取此表,它会公布每个模型接受的参数及其范围。supported_parameters中未出现的参数,表示该端点不支持。
Seed 在 FLUX.2 Klein 上完全复现了该图像
seed 是你发送的用于让结果可复现的数字。在我们目录中的每个 Gemini、Grok、OpenAI、Riverflow、Recraft 和 MAI 图像模型上都缺失它。它存在于 FLUX.2、Seedream、Qwen 和 Krea 上。
我们运行了black-forest-labs/flux.2-klein-4b两次,使用相同的提示词,以及seed: 424242。两次响应逐字节完全一致,且均计费 $0.014。我们只测试了 Klein,因此其他支持 seed 的模型应视为未经测试,而不要假设它们的行为相同。作为对比,两次sourceful/riverflow-v2.5-fast不带 seed 参数的调用,在相同的请求体下返回了两张不同的图像。
排行榜怎么说
我们在每个模型的页面上展示 Design Arena 评分。当我们在 2026 年 9 月 11 日通过 benchmarks API 拉取当前评分时,sourceful/riverflow-v2.5-pro 在图像榜和图像编辑榜上都获得了最高评分。微软的 MAI Image 2.6 模型和 Google 的 Gemini 图像模型在图像榜上紧随其后,而 black-forest-labs/flux.2-klein-4b 在两个榜单所列模型中评分最低。
这些评分来自模型之间的两两对战投票,Design Arena 将其转化为 Elo 评分——当模型赢下一场对决时分数上升,输掉时则下降。
有两点需要注意。Gemini 的评分基于这些 slug 的 -preview 版本,而非我们在本页链接的正式发布版本。而且 Elo 告诉你的是投票者在其提示词上的偏好,而非你的。在我们这次运行中,评分最高的模型每张图片收费 $0.064,评分最低的模型收费 $0.014。先从榜单中筛选出候选,再根据自己的提示词做决定。
我们用同一个提示词测试了六个模型
我们把同一个提示词发送给了横跨不同价位的六个模型,并将费用标注在每张图片下方。我们要求生成一个哑光黑色的咖啡袋,上面印有两行文字。
提示词
一张哑光黑色咖啡包装袋的影棚产品照,置于纯白背景之上,采用硬质主光。袋子正面以简洁的无衬线大写字母印着 OPENROUTER ROASTERS 字样,其下方以较小的无衬线大写字母印着 SINGLE ORIGIN 字样。
我们选择可读的文字,是因为它们容易评分。袋子要么写着你要求的内容,要么没有。

图 2. 同一提示词经由六个模型生成,并附上每次调用的实测成本。
六个中有五个把两行都印对了。例外是 black-forest-labs/flux.2-klein-4b,它把品牌名渲染正确,却把第二行拼错成了 SINGLE ORISION。
最有用的比较,是 Design Arena 榜单上最便宜的模型与最贵的模型之间的对比。openai/gpt-image-2 计费 $0.0135,sourceful/riverflow-v2.5-pro 计费 $0.0654,两者都生成了正确、可用的商品图。多花约五倍的钱,换来的是不同的观感,而不是更好的文字。
这并不意味着 Riverflow 定价过高。它领跑 Design Arena 各榜单,而在更难的图像、不寻常的构图或更长的文本串上,差距可能会显现出来。它真正说明的是,无论是排行榜还是价格栏,都没能预测出这个提示词上的结果,只有实际跑一遍提示词才能知道。
同一次测试还带出了两个较小的发现。在按 token 计费的模型上,提示词长度会改变你的账单,因为 openai/gpt-image-2 在之前那行单行提示词上计费 $0.006,而在这个更长的提示词上计费 $0.0135。另外,每个模型对“studio packshot”的理解都不同,从硬阴影的产品照到柔光的产品照都有,所以构图是一个需要测试的风格选择。
按任务挑选
根据对你而言最紧的那项约束来挑选模型。那可能是大批量下的成本、图像是否必须包含可读的文字、你需要发送多少张参考图,或者回复是否需要在图片之外附带文字。
大批量、普通提示词
从 openai/gpt-image-2 开始。在成本表中,它在短提示词上计费 $0.006,在较长的咖啡袋提示词上计费 $0.0135,因为它是按 token 计费的,你的提示词也是账单的一部分。对于长度相近的产品提示词,按这个区间做预算。它是我们测过的最便宜的模型,并且以最低的成本正确渲染了我们的文字。
black-forest-labs/flux.2-klein-4b 以 $0.014 成为另一个便宜选项,但有一个实测到的坑。它是六款模型中唯一拼错标签的,而且在两个榜单上都是 Design Arena 评分最低的模型。把它用于画面中没有可读文字的批量工作。当产品名称必须准确呈现时,不要用它。
OpenAI 的这些数字假设你保持 quality 未设置。把它调到 high 后,我们账单上那一行变成了 35 倍。Klein 没有 quality 设置,所以它的成本更容易预测,而且当你需要更好的结果时,也没有可调高的设置。
在咖啡袋提示词上,两者分别为 $0.0135 和 $0.014,也就是一万张图片 $135 对 $140。到了这个程度,价格已经不能决定什么了,所以把你自己的提示词分别跑一遍,让输出结果来决定。
关于 Klein 有一条操作上的说明。Black Forest Labs 在 Hugging Face 上发布其权重,仓库名为 black-forest-labs/FLUX.2-klein-4B,而不是使用我们 slug 的大小写形式。你现在可以通过我们调用它,之后再迁到内部,而无需更换你所围绕构建的模型家族。
图片中的文字
当模型把产品名称弄错时,包装、UI 模型图、幻灯片和海报都会出问题。
我们测试的六个模型中有五个无需任何辅助就能处理两行标签,所以可以按成本和风格来挑选,然后拿结果与你自己的文字而非我们的文字进行核对。
black-forest-labs/flux.2-flex 正确渲染了我们的标签,该图片计费 $0.05,并且最多接受八张参考图。如果你已经在使用 FLUX.2 且文字很重要,这就是应该迁移到的 FLUX.2 模型。如果你还没有锁定某个模型家族,openai/gpt-image-2 以大约四分之一的价格完成了同样的工作。
在做决定之前,看看 recraft/recraft-v4.1-vector,它以不同的方式解决了这个问题。它返回的是 SVG 而非像素,其端点接受 style、controls 和 text_layout 作为 provider.options 下的透传参数。对于需要缩放并保持可编辑的 logo 或标签,矢量输出胜过更清晰的位图,而每张图片 $0.08 就能得到一个可以在设计工具中打开的文件。
参考一致的品牌作品
在这里,同一个物体在它出现的所有地方都必须看起来一样。产品页面上的瓶子和宣传图中的同一个瓶子不应该出现偏差。
我们测试了这一点。我们拿来了openai/gpt-image-2已经做好的咖啡袋,将其作为input_references图像发回去,并要求四个模型在保持袋子及其印刷标签完全不变的前提下,将白色背景替换为暖色侧光下的深胡桃木台面。

图 3. 一张源图像、一条指令、四个模型,以及每次编辑的实测成本。
四个模型都保留了文字内容和字体。四个模型也都在一定程度上改变了袋子的形状、比例或光照,且没有一个能逐像素还原源袋子,因此如果一次营销活动中的每张图像都必须与一张主视觉图保持一致,应将输出结果与源图进行对比,而不是仅凭标签来判断。
为了公平地比较编辑与生成,我们还使用编辑指令作为提示词运行了生成一侧,因此两列来自相同的措辞。这一点很重要,因为这些模型中有两个按 token 计费,更长的提示词本身就会带来更高的账单。
| 模型 | 生成 | 编辑 |
|---|---|---|
| openai/gpt-image-2 | $0.0133 | $0.0142 |
| black-forest-labs/flux.2-pro | $0.0300 | $0.0450 |
| google/gemini-3-pro-image | $0.1345 | $0.1356 |
| sourceful/riverflow-v2.5-pro | $0.0646 | $0.0760 |
black-forest-labs/flux.2-pro 的编辑费用又贵了一半。其编辑响应报告了 4,096 个提示词 token,而生成响应只报告了 34 个,这说明参考图像被计入了输入,而且其端点只列出了输出百万像素的费率,因此仅凭列出的费率无法预测编辑价格。sourceful/riverflow-v2.5-pro 的编辑费用贵了 18%。在 openai/gpt-image-2 和 google/gemini-3-pro-image 上,差距不到 7%。这些都是单次运行,因此请将较小的差距视为近似值,而非精确的溢价。
有两个数字可以缩小编辑功能的候选范围,即模型接受多少张参考图像,以及它在 Design Arena 图像编辑榜单上的评分。
black-forest-labs/flux.2-pro 接受八张参考图像,生成费用为 $0.03,编辑费用为 $0.045。black-forest-labs/flux.2-max 同样提供八张参考图像,每张生成图像的费用为 $0.07。
如果你的品牌套件超过八张图片,FLUX.2 就无法接收。Gemini 3.x 图像模型和 Seedream 5.0 可以接收十四张,OpenAI 的图像模型可以接收十六张。Grok 上限为三张。
同时包含图片和文字的回复
有时用户正在进行一段对话,而回答应当同时包含一张图片和一段文字说明。我们目录中 52 个模型里有九个将文本列为其输出模态之一,它们就是能够做到这一点的模型。它们是 Gemini 图像模型和 OpenAI 的 gpt-5-image 模型。
能够返回文本和实际做到是两回事。我们选取了这九个中的四个,通过 chat completions 端点向每个模型发送了相同的请求,并带上 modalities: ["image", "text"],要求给出一张图片外加两句话的解释,然后统计我们同时得到两者的频率。这些成本高于这些模型在成本表中的数字,因为回复中带有文本,而在按 token 计费的模型上,两者你都要付费。
| 模型 | 带文本的回复 | 每次调用成本 |
|---|---|---|
| openai/gpt-5-image | 3 个中的第 2 个 | $0.20 至 $0.28 |
| google/gemini-3-pro-image | 3 / 3 | $0.138 至 $0.140 |
| google/gemini-3.1-flash-image | 1 / 4 | $0.067 |
| google/gemini-3.1-flash-lite-image | 0 / 2 | $0.034 |
上述每一次调用都至少返回了一张图片。google/gemini-3-pro-image 每次调用返回了两张图片。差异在于文字那一半,而那两个更便宜的 Gemini 模型大多跳过了它,尽管提示词直接要求了这一点。
如果文字是可选的,google/gemini-3.1-flash-image 以 $0.067 的价格可用,你自行处理空返回的情况。如果你的产品缺少文字就无法运行,那么 google/gemini-3-pro-image 以约 $0.139 的价格是四款模型中唯一在我们的测试中每次都返回文字的模型。
我们建议在新的图像工作中使用专用的 Image API,而非 chat completions,因为新的图像模型只会添加到 Image API,而 chat 路由提供的参数更少。openai/gpt-5-image 也是这里最贵的选项,每次调用 $0.20 到 $0.28,而且它在三次调用中有两次返回了文本。这些 chat 调用会在图像之外额外对提示词和补全 token 计费,因此一段很长的指令和一个很长的回答会比单张图像的价格更贵。
三项任务,两个端点
生成、编辑和聊天看起来相似,但它们是不同的请求。生成和编辑使用 images 端点,仅相差一个字段。聊天则改用 chat completions 端点,只有上面九个具备文本能力的模型才能做到。我们的OpenRouter 上的图像生成模型教程涵盖了这两个端点的完整请求和响应契约。
![Diagram of three request shapes. Generate and edit both go to POST /api/v1/images, and edit adds an input_references array. Chat goes to POST /api/v1/chat/completions. The Image API response carries data[].b64_json, data[].media_type, and usage.cost. The chat response carries message.content and message.images.](/api/img-proxy?u=https%3A%2F%2Fopenrouter.ai%2Fblog%2Fimages%2Fimage-generation-endpoints.png&exp=1789819200&sig=dcb24816caa3a4284634ab63b189d55d5bf2754bf6230afd832e6acd91753e62)
图 4。生成和编辑是同一个端点,只是请求体不同。聊天则是另一个端点。
生成就是 POST /api/v1/images 加上一个 model 和一个 prompt。你会得到图像字节作为返回。
编辑是同一个端点加上 input_references,因为你是在修改一张已有的图像,而不是生成一张新的。
聊天发送一个messages数组到POST /api/v1/chat/completions。文本和图像输入,文本和图像也可以返回。
在 OpenRouter 上调用它
图像路由是 POST https://openrouter.ai/api/v1/images。唯一必填字段是 model 和 prompt。
curl https://openrouter.ai/api/v1/images \
-H "Authorization: Bearer $OPENROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "black-forest-labs/flux.2-klein-4b",
"prompt": "A studio packshot of a glass bottle, hard key light, no text.",
"aspect_ratio": "1:1"
}' 响应中包含图像及其费用。这是我们在 2026 年 9 月 11 日针对该请求收到的响应,已裁剪为本文讨论的字段,并移除了图像字节。
{
"data": [
{
"b64_json": "<base64>",
"media_type": "image/jpeg"
}
],
"usage": {
"prompt_tokens": 16,
"completion_tokens": 4096,
"total_tokens": 4112,
"cost": 0.014,
"completion_tokens_details": {
"image_tokens": 4096
}
}
} 要改为编辑图像,请在同一请求体中添加一个 input_references 数组。每个条目都是一个 image_url 对象,携带 HTTP(S) URL 或 base64 数据 URL。
{
"model": "black-forest-labs/flux.2-pro",
"prompt": "Keep the bag and its printed label exactly as they are. Replace the white background with a dark walnut counter under warm side light.",
"aspect_ratio": "1:1",
"input_references": [
{
"type": "image_url",
"image_url": {
"url": "data:image/png;base64,<base64>"
}
}
]
} 我们的 TypeScript SDK 封装了同一路由,并将字段名转换为驼峰式,因此 b64_json 变为 b64Json,media_type 变为 mediaType,而 aspect_ratio 变为 aspectRatio。generate 方法的返回类型也涵盖了流式场景,因此在读取 data 属性之前,请先对其进行类型收窄。
import { OpenRouter } from '@openrouter/sdk';
const openRouter = new OpenRouter({ apiKey: process.env.OPENROUTER_API_KEY ?? '' });
const result = await openRouter.images.generate({
imageGenerationRequest: {
model: 'black-forest-labs/flux.2-klein-4b',
prompt: 'A studio packshot of a glass bottle, hard key light, no text.',
aspectRatio: '1:1',
},
});
if (!('data' in result)) {
throw new Error('Expected a non-streaming image response');
}
const image = result.data[0]?.b64Json;
const mediaType = result.data[0]?.mediaType;
const cost = result.usage?.cost; 常见问题
2026 年最佳的图像生成模型是什么?
没有单一的最佳模型,所以要按任务来选。在我们 2026 年 9 月 11 日的测试中,openai/gpt-image-2 是我们测到的最便宜的模型,根据提示词长度不同,每张图像收费 $0.006 到 $0.0135,并且它正确渲染了两行标签和一次参考编辑。sourceful/riverflow-v2.5-pro 在 Design Arena 图像和图像编辑榜单上领先,每张图像收费 $0.064。recraft/recraft-v4.1-vector 以每张图像 $0.08 的价格返回可编辑的 SVG。
OpenRouter 上最便宜的图像生成模型是哪个?
在我们以 1024x1024 分辨率、默认设置测量的 20 个模型中,openai/gpt-image-2 收费最低,一行提示词为 $0.00599。black-forest-labs/flux.2-klein-4b 收费 $0.014,sourceful/riverflow-v2.5-fast 收费 $0.0176。在按 token 计费的模型上,提示词长度会改变账单,而在 OpenAI 模型上,quality 设置让同一张图像的费用从 $0.006 变为 $0.211。
哪些图像模型可以编辑现有图像?
任何端点列出 input_references 的模型都通过 POST /api/v1/images 接受参考图像。上限因模型而异。在 2026 年 9 月 11 日,OpenAI 图像模型接受 16 张,Gemini 3.x 图像模型和 Seedream 5.0 接受 14 张,sourceful/riverflow-v2.5-pro 接受 10 张,FLUX.2 Flex、Pro 和 Max 接受 8 张,FLUX.2 Klein 和 Qwen Image 3 接受 4 张,Grok Imagine 接受 3 张,Recraft、Krea 和 MAI Image 接受 1 张。请阅读 GET /api/v1/images/models/{model}/endpoints 了解当前数值。
哪些图像模型可以同时回复文本和图像?
输出模态包含文本的模型。在 2026 年 9 月 11 日,我们目录中的 52 个图像模型里有九个属于此类,即所有 Gemini 图像模型和 OpenAI gpt-5-image 模型。通过 POST /api/v1/chat/completions 调用它们。在我们的测试中,google/gemini-3-pro-image 在 3 次调用中有 3 次返回了文本,openai/gpt-5-image 在 3 次中有 2 次,google/gemini-3.1-flash-image 在 4 次中有 1 次,google/gemini-3.1-flash-lite-image 在 2 次中有 0 次。
Image API 返回什么图像格式?
这取决于模型。在我们的运行中,FLUX.2、Grok 和 Seedream 返回 JPEG,OpenAI、Qwen、Microsoft 和 Krea 返回 PNG,Sourceful 和 Recraft 返回 WebP,而 recraft/recraft-v4.1-vector 返回 SVG。目录中的 52 个模型里有十二个接受 output_format 参数。请读取每个响应上的 media_type 字段,而不要假设文件扩展名。
We route 52 image generation models through one API. We ran the same prompt through 20 of them and recorded what each call billed, what it returned, and what it accepts.
Cost is the hard part, because these models are not sold in the same unit. FLUX.2 is priced per megapixel. Gemini, OpenAI, and Microsoft MAI are priced per token. Grok, Recraft, Riverflow, Qwen, and Seedream are priced per image, at a rate that changes with the quality and resolution you ask for. Each model page is correct in its own unit, so you cannot compare two of them by reading their prices side by side.
We put them on the same footing. The 20 models we tested all got the same prompt at the same size, and we read the usage.cost field from each response, which is the amount we charged.
Every price on this page came from a real generation, measured on 11 September 2026. Prices and models change often, so treat any figure more than a month old as a hint rather than a budget line. You can re-pull the current state with
GET /api/v1/images/modelsfor accepted parameters andGET /api/v1/images/models/{model}/endpointsfor pricing with the unit named.
Summary
- Start with openai/gpt-image-2. It billed $0.006 on a short prompt and $0.0135 on a longer one, which made it the cheapest model we measured, and it rendered our two-line label and our reference edit correctly.
- Reach past it for sourceful/riverflow-v2.5-pro at $0.064 when the image is hard to get right, google/gemini-3-pro-image at $0.134 when the reply needs words as well as a picture, and recraft/recraft-v4.1-vector at $0.08 when you need editable SVG instead of pixels.
- One image at default settings billed between $0.006 and $0.134 across the 20 models we measured, a 22x spread.
- Every model page quotes its price in its own unit, and the billed cost can differ from the listed rate. The way to compare two models is to generate one image with each and read
usage.costoff the response. - On OpenAI models, the
qualitysetting moved the same image from $0.006 to $0.211. n, the number of images you get back from one call, is capped at 1 on FLUX.2, Gemini, Grok, Riverflow, and MAI.seeddoes not exist on Gemini, Grok, OpenAI, Riverflow, Recraft, or MAI. Where it exists on FLUX.2 Klein, the same seed reproduced the image byte for byte.- Five of the six models we asked for readable text rendered it correctly, including the cheapest one.
- The raw API returns
data[0].b64_json. The TypeScript SDK returnsdata[0].b64Json.
What each model billed us
We sent each of these 20 models the prompt “A studio packshot of a glass bottle, hard key light, no text.” with aspect_ratio: "1:1" and no other settings, then read usage.cost off the response. The billing unit column is the unit field from each endpoint’s pricing record.
| Model | Billed | Returned | Format | Billing unit |
|---|---|---|---|---|
| openai/gpt-image-2 | $0.0060 | 1024x1024 | PNG | token |
| black-forest-labs/flux.2-klein-4b | $0.0140 | 1024x1024 | JPEG | megapixel |
| sourceful/riverflow-v2.5-fast | $0.0176 | 1024x1024 | WebP | image |
| black-forest-labs/flux.2-pro | $0.0300 | 1024x1024 | JPEG | megapixel |
| qwen/qwen-image-3 | $0.0300 | 1024x1024 | PNG | image |
| krea/krea-2-medium | $0.0300 | 1024x1024 | PNG | not published |
| openai/gpt-image-1-mini | $0.0333 | 1024x1024 | PNG | token |
| google/gemini-3.1-flash-lite-image | $0.0336 | 1024x1024 | JPEG | token |
| recraft/recraft-v4.1 | $0.0350 | 1024x1024 | WebP | image |
| bytedance-seed/seedream-5-0-lite | $0.0350 | 2048x2048 | JPEG | image |
| microsoft/mai-image-2.5 | $0.0482 | 1024x1024 | PNG | token |
| black-forest-labs/flux.2-flex | $0.0500 | 1024x1024 | JPEG | megapixel |
| x-ai/grok-imagine-image-quality | $0.0500 | 1024x1024 | JPEG | image |
| x-ai/grok-imagine-image-2.0 | $0.0600 | 1024x1024 | JPEG | image |
| sourceful/riverflow-v2.5-pro | $0.0641 | 1024x1024 | WebP | image |
| google/gemini-3.1-flash-image | $0.0672 | 1024x1024 | PNG | token |
| black-forest-labs/flux.2-max | $0.0700 | 1024x1024 | JPEG | megapixel |
| recraft/recraft-v4.1-vector | $0.0800 | vector | SVG | image |
| bytedance-seed/seedream-5-0-pro | $0.0900 | 2048x2048 | JPEG | image |
| google/gemini-3-pro-image | $0.1344 | 1024x1024 | PNG | token |

Figure 1. The same prices, sorted. The three billing units are mixed all the way up the range, so the unit does not tell you where a model lands in it.
Three things to know before you budget from this table.
- Both Seedream models returned 2048x2048 instead of 1024x1024 when we left
resolutionunset. Seedream 5.0 Lite lists2Kas the lowest resolution it accepts. Seedream 5.0 Pro accepts1K, but its default call returned 2K and billed its $0.09 high-resolution rate rather than its $0.045 base rate. Seedream 5.0 Lite gives you four megapixels for $0.035, so per pixel it is cheaper than the table makes it look. - FLUX.2, Grok, and Seedream returned JPEG. OpenAI, Qwen, Microsoft, and Krea returned PNG. Sourceful and Recraft returned WebP, and Recraft’s vector model returned SVG. The three Gemini models we tested do not accept
output_format, and they did not all return the same format, so do not hard-code a file extension. Setoutput_formaton the twelve catalog models that accept it. On the ones that do not, read themedia_typefield that comes back with every response. - Two calls to
sourceful/riverflow-v2.5-fastwith the same request body billed $0.017623 and $0.017639. Budget from an average of several calls rather than from one.
The quality setting moves the price 35x
On OpenAI models, quality changes your bill more than any other setting. We ran gpt-image-2 with the same prompt at the same 1024x1024 size with quality unset, set to low, and set to high.
| quality | Image tokens | Billed |
|---|---|---|
| unset | 196 | $0.00599 |
| low | 196 | $0.00599 |
| high | 7,024 | $0.21083 |
Leaving quality unset gave us the same token count and bill as low. Set quality explicitly when the image matters, and treat a per-image price for an OpenAI model as incomplete unless it names the quality tier. The high call also took 123 seconds to return against 12 seconds for the default call.
Aspect ratio moves the bill much less
On a per-megapixel model, the frame you ask for changes the bill, but by less than the pixel count suggests. We ran black-forest-labs/flux.2-klein-4b at two shapes. The 21:9 call returned 2400x1024, which is 2.46 megapixels against 1.05 for the square. We were billed $0.014 for the square and $0.016 for the wide crop.
Listed rates and billed cost can differ
Each model publishes a rate on its page and on the API’s endpoints route. Those rates are a planning number, and the response is what you pay. On 11 September 2026, sourceful/riverflow-v2.5-pro listed $0.13 per image at its default resolution and billed us $0.064. black-forest-labs/flux.2-flex listed $0.06 per megapixel and billed us $0.05 for a one-megapixel image. black-forest-labs/flux.2-max listed $0.07 and billed us exactly $0.07. krea/krea-2-medium published no pricing record on its endpoint and billed us $0.03.
When the two disagree, read usage.cost rather than multiplying a listed rate by an estimate.
We bill a completed image request in full and charge nothing for one that fails. The Image API billing documentation describes which outcomes are billed.
References, formats, and limits
Price is one axis. These are the others, and two of them rule models out before cost matters at all. The values come from each endpoint’s supported_parameters on 11 September 2026.
| Family | Output modalities | Max reference images | output_format | Images per call (n) | seed |
|---|---|---|---|---|---|
| FLUX.2 Klein | image | 4 | png, jpeg | 1 | yes |
| FLUX.2 Flex, Pro, Max | image | 8 | png, jpeg | 1 | yes |
| Gemini 3.x image | image, text | 14 | not settable | 1 | no |
| Grok Imagine Image | image | 3 | not settable | 1 | no |
| OpenAI gpt-image | image | 16 | not settable | 1 to 10 | no |
| OpenAI gpt-5-image | image, text | 16 | not settable | 1 to 10 | no |
| Seedream 5.0 | image | 14 | not settable | 1 to 4 on Lite, 1 on Pro | yes |
| Recraft v4.1 | image | 1 | svg on the vector model | 1 to 6 | no |
| Qwen Image 3 | image | 4 | not settable | 1 to 6 | yes |
| Riverflow 2.5 | image | 4 on Fast, 10 on Pro | jpeg on Fast, png, jpeg, webp on Pro | 1 | no |
| Microsoft MAI Image 2.5 | image | 1 | not settable | 1 | no |
| Krea 2 Medium | image | 1 | not settable | n not published | yes |
A reference image is one you send with the request for the model to work from, either an image you want edited or an example of the style or product you want matched. The limit on how many you can send is a hard ceiling. Grok takes three and Gemini takes fourteen, so a six-image brand kit rules Grok out before you compare anything else.
The output modalities column is the second axis. Most of these models take text and images in and return only image bytes. The Gemini image models and OpenAI’s gpt-5-image models can also return written text in the same reply, which matters if you want the model to explain what it made. We tested how reliably they do that further down.
Re-pull this table for any model with
GET /api/v1/images/models, which publishes each model’s accepted parameters and their ranges. A parameter that is absent fromsupported_parametersis not supported on that endpoint.
Seed reproduced the image exactly on FLUX.2 Klein
seed is the number you send to make a result repeatable. It is missing from every Gemini, Grok, OpenAI, Riverflow, Recraft, and MAI image model on our catalog. It exists on FLUX.2, Seedream, Qwen, and Krea.
We ran black-forest-labs/flux.2-klein-4b twice with the same prompt and seed: 424242. The two responses were identical byte for byte, and both billed $0.014. We only tested Klein, so treat the other seed-capable models as untested rather than assuming they behave the same way. For comparison, two sourceful/riverflow-v2.5-fast calls with no seed parameter returned two different images from the same request body.
What the leaderboards say
We show Design Arena ratings on each model’s page. When we pulled the current ratings through our benchmarks API on 11 September 2026, sourceful/riverflow-v2.5-pro had the highest rating on both the image board and the image editing board. Microsoft’s MAI Image 2.6 models and Google’s Gemini image models followed on the image board, and black-forest-labs/flux.2-klein-4b had the lowest rating of the models listed on both boards.
Those ratings come from head-to-head votes between models, which Design Arena turns into an Elo rating, a score that rises when a model wins a matchup and falls when it loses.
Two caveats. The Gemini ratings sit on the -preview versions of those slugs rather than the general release slugs we link on this page. And Elo tells you what voters preferred on their prompts, not yours. The top-rated model billed $0.064 per image in our run and the lowest-rated one billed $0.014. Shortlist from the board, then decide from your own prompts.
We ran one prompt through six models
We sent one prompt to six models across the price range and put the bill under each image. We asked for a matte black coffee bag with two lines of text printed on it.
Prompt
A studio packshot of a matte black coffee bag on a plain white background, hard key light. Printed across the front of the bag in clean sans-serif capitals are the words OPENROUTER ROASTERS, and beneath that in smaller capitals the words SINGLE ORIGIN.
We picked readable words because they are easy to grade. Either the bag says what you asked for or it does not.

Figure 2. The same prompt through six models, with the measured cost of each call.
Five of the six printed both lines correctly. The exception is black-forest-labs/flux.2-klein-4b, which rendered the brand name correctly and misspelled the second line as SINGLE ORISION.
The most useful comparison is the cheapest model against the most expensive one on the Design Arena board. openai/gpt-image-2 billed $0.0135 and sourceful/riverflow-v2.5-pro billed $0.0654, and both produced a correct, usable packshot. Spending about five times more gave us a different look, not better text.
That does not make Riverflow overpriced. It leads the Design Arena boards, and on a harder image, an unusual composition, or a longer string of text, the gap may show. What it does mean is that neither the leaderboard nor the price column predicted the result on this prompt, and only running the prompt did.
Two smaller things came out of the same test. Your prompt length changes your bill on the per-token models, since openai/gpt-image-2 billed $0.006 on the one-line prompt earlier and $0.0135 on this longer one. And every model read “studio packshot” differently, from a hard-shadow product shot to a soft-lit one, so composition is a style choice to test.
Pick by job
Pick the model on whichever constraint is tightest for you. That may be cost at volume, whether the image has to contain readable words, how many reference images you need to send, or whether the reply needs text alongside the picture.
High volume, ordinary prompts
Start with openai/gpt-image-2. It billed $0.006 on the short prompt in the cost table and $0.0135 on the longer coffee-bag prompt, because it is priced per token and your prompt is part of the bill. Budget in that range for product prompts of similar length. It is the cheapest model we measured and it rendered our text correctly for the least money.
black-forest-labs/flux.2-klein-4b at $0.014 is the other cheap option, with one measured catch. It was the only model of the six that misspelled the label, and it had the lowest Design Arena rating of the models on both boards. Use it for volume work with no readable words in the frame. Do not use it when a product name has to come out right.
The OpenAI figures assume you leave quality unset. Moving it to high multiplied that line of our bill by 35. Klein has no quality setting, so its cost is easier to forecast and there is no setting to raise when you need a better result.
On the coffee-bag prompt the two came out at $0.0135 and $0.014, which is $135 against $140 for ten thousand images. At that point price is not deciding anything, so run your own prompts through both and let the output decide.
One operational note about Klein. Black Forest Labs publishes its weights on Hugging Face, where the repository is named black-forest-labs/FLUX.2-klein-4B rather than using our slug’s capitalization. You can call it through us now and move it in-house later without changing the model family you built around.
Words inside the picture
Packaging, UI mockups, slides, and posters fail when the model garbles a product name.
Five of the six models we tested handled a two-line label with no help, so pick on cost and style, then check the result against your own words rather than ours.
black-forest-labs/flux.2-flex rendered our label correctly, billed $0.05 for the image, and takes up to eight reference images. If you are already on FLUX.2 and the words matter, it is the FLUX.2 model to move to. If you are not committed to a family, openai/gpt-image-2 did the same job for about a quarter of the price.
Before you settle, look at recraft/recraft-v4.1-vector, which solves the problem differently. It returns SVG rather than pixels, and its endpoint accepts style, controls, and text_layout as passthrough parameters under provider.options. For a logo or a label that has to scale and stay editable, vector output beats a sharper raster, and $0.08 an image gets you a file you can open in a design tool.
Reference-consistent brand work
Here, the same object has to look the same everywhere it appears. A bottle on the product page and the same bottle in a campaign image should not drift apart.
We tested this. We took the coffee bag openai/gpt-image-2 had already made, sent it back as an input_references image, and asked four models to keep the bag and its printed label exactly as they were while replacing the white background with a dark walnut counter under warm side light.

Figure 3. One source image, one instruction, four models, with the measured cost of each edit.
All four kept the wording and the typeface. All four also changed the bag’s shape, proportions, or lighting to some degree, and none reproduced the source bag pixel for pixel, so if every image in a campaign has to match one hero shot, compare the outputs against the source rather than reading the label alone.
To compare editing against generating fairly, we also ran the generate side using the edit instruction as the prompt, so both columns come from the same wording. That matters because two of these models bill per token, where a longer prompt is a bigger bill on its own.
| Model | Generate | Edit |
|---|---|---|
| openai/gpt-image-2 | $0.0133 | $0.0142 |
| black-forest-labs/flux.2-pro | $0.0300 | $0.0450 |
| google/gemini-3-pro-image | $0.1345 | $0.1356 |
| sourceful/riverflow-v2.5-pro | $0.0646 | $0.0760 |
black-forest-labs/flux.2-pro billed half as much again for the edit. Its edit response reported 4,096 prompt tokens where the generate response reported 34, which is the reference image being counted as input, and its endpoint lists a rate for output megapixels only, so the listed rate alone does not predict the edit price. sourceful/riverflow-v2.5-pro billed 18 percent more for the edit. On openai/gpt-image-2 and google/gemini-3-pro-image the gap was under 7 percent. These are single runs, so read the small gaps as approximate rather than as precise premiums.
Two numbers narrow the field for editing, namely how many reference images the model accepts and how it rates on the Design Arena image editing board.
black-forest-labs/flux.2-pro takes eight references and billed $0.03 to generate and $0.045 to edit. black-forest-labs/flux.2-max gives you the same eight references at $0.07 per generated image.
If your brand kit runs past eight images, FLUX.2 cannot take it. The Gemini 3.x image models and Seedream 5.0 take fourteen, and the OpenAI image models take sixteen. Grok caps at three.
A reply with both a picture and text
Sometimes the user is in a conversation and the answer should include an image and a written explanation. Nine of the 52 models on our catalog list text among their output modalities, and they are the ones that can do this. They are the Gemini image models and OpenAI’s gpt-5-image models.
Being able to return text and doing it are different things. We took four of the nine, sent each the same request through the chat completions endpoint with modalities: ["image", "text"], asked for an image plus a two-sentence explanation, and counted how often we got both. These costs are higher than the same models’ figures in the cost table because the reply carries text, and on a per-token model you pay for both.
| Model | Replies with text | Cost per call |
|---|---|---|
| openai/gpt-5-image | 2 of 3 | $0.20 to $0.28 |
| google/gemini-3-pro-image | 3 of 3 | $0.138 to $0.140 |
| google/gemini-3.1-flash-image | 1 of 4 | $0.067 |
| google/gemini-3.1-flash-lite-image | 0 of 2 | $0.034 |
Every one of those calls returned at least one image. google/gemini-3-pro-image returned two images per call. The difference is the written half, and the two cheaper Gemini models mostly skipped it even though the prompt asked for it directly.
If the text is optional, google/gemini-3.1-flash-image at $0.067 works and you handle the empty case. If your product breaks without the text, google/gemini-3-pro-image at about $0.139 was the only model of the four that answered with text every time in our run.
We recommend the dedicated Image API over chat completions for new image work, because new image models are added only to the Image API and the chat route gives you fewer parameters. openai/gpt-5-image was also the most expensive option here at $0.20 to $0.28 a call, and it returned text in two of three calls. These chat calls bill prompt and completion tokens on top of the image, so a long instruction and a long answer cost more than the per-image figure.
Three jobs, two endpoints
Generating, editing, and chatting look similar, but they are different requests. Generating and editing use the images endpoint and differ by one field. Chatting uses the chat completions endpoint instead, and only the nine text-capable models above can do it. Our Image Generation Models on OpenRouter tutorial covers the full request and response contract for both endpoints.
![Diagram of three request shapes. Generate and edit both go to POST /api/v1/images, and edit adds an input_references array. Chat goes to POST /api/v1/chat/completions. The Image API response carries data[].b64_json, data[].media_type, and usage.cost. The chat response carries message.content and message.images.](/api/img-proxy?u=https%3A%2F%2Fopenrouter.ai%2Fblog%2Fimages%2Fimage-generation-endpoints.png&exp=1789819200&sig=dcb24816caa3a4284634ab63b189d55d5bf2754bf6230afd832e6acd91753e62)
Figure 4. Generating and editing are one endpoint with a different body. Chatting is a different endpoint.
Generating is POST /api/v1/images with a model and a prompt. You get image bytes back.
Editing is the same endpoint with input_references added, because you are changing an image you already have instead of making a new one.
Chatting sends a messages array to POST /api/v1/chat/completions. Text and images go in, and text and images can come back.
Call it on OpenRouter
The images route is POST https://openrouter.ai/api/v1/images. The only required fields are model and prompt.
curl https://openrouter.ai/api/v1/images \
-H "Authorization: Bearer $OPENROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "black-forest-labs/flux.2-klein-4b",
"prompt": "A studio packshot of a glass bottle, hard key light, no text.",
"aspect_ratio": "1:1"
}' The response includes the image and its cost. This is the response we received for that request on 11 September 2026, trimmed to the fields this article discusses and with the image bytes removed.
{
"data": [
{
"b64_json": "<base64>",
"media_type": "image/jpeg"
}
],
"usage": {
"prompt_tokens": 16,
"completion_tokens": 4096,
"total_tokens": 4112,
"cost": 0.014,
"completion_tokens_details": {
"image_tokens": 4096
}
}
} To edit an image instead, add an input_references array to the same body. Each entry is an image_url object carrying either an HTTP(S) URL or a base64 data URL.
{
"model": "black-forest-labs/flux.2-pro",
"prompt": "Keep the bag and its printed label exactly as they are. Replace the white background with a dark walnut counter under warm side light.",
"aspect_ratio": "1:1",
"input_references": [
{
"type": "image_url",
"image_url": {
"url": "data:image/png;base64,<base64>"
}
}
]
} Our TypeScript SDK wraps the same route and camel-cases the field names, so b64_json becomes b64Json, media_type becomes mediaType, and aspect_ratio becomes aspectRatio. The generate method’s return type also covers the streaming case, so narrow on the data property before you read it.
import { OpenRouter } from '@openrouter/sdk';
const openRouter = new OpenRouter({ apiKey: process.env.OPENROUTER_API_KEY ?? '' });
const result = await openRouter.images.generate({
imageGenerationRequest: {
model: 'black-forest-labs/flux.2-klein-4b',
prompt: 'A studio packshot of a glass bottle, hard key light, no text.',
aspectRatio: '1:1',
},
});
if (!('data' in result)) {
throw new Error('Expected a non-streaming image response');
}
const image = result.data[0]?.b64Json;
const mediaType = result.data[0]?.mediaType;
const cost = result.usage?.cost; FAQ
What is the best image generation model in 2026?
There is no single best model, so pick by job. In our 11 September 2026 run, openai/gpt-image-2 was the cheapest model we measured at $0.006 to $0.0135 per image depending on prompt length, and it rendered a two-line label and a reference edit correctly. sourceful/riverflow-v2.5-pro led the Design Arena image and image editing boards and billed $0.064 per image. recraft/recraft-v4.1-vector returns editable SVG at $0.08 per image.
Which image generation model is cheapest on OpenRouter?
Of the 20 models we measured at 1024x1024 with default settings, openai/gpt-image-2 billed the least at $0.00599 for a one-line prompt. black-forest-labs/flux.2-klein-4b billed $0.014, and sourceful/riverflow-v2.5-fast billed $0.0176. On per-token models the prompt length changes the bill, and on OpenAI models the quality setting moved the same image from $0.006 to $0.211.
Which image models can edit an existing image?
Any model whose endpoint lists input_references accepts reference images through POST /api/v1/images. The limit varies by model. On 11 September 2026, OpenAI image models accepted 16, Gemini 3.x image models and Seedream 5.0 accepted 14, sourceful/riverflow-v2.5-pro accepted 10, FLUX.2 Flex, Pro, and Max accepted 8, FLUX.2 Klein and Qwen Image 3 accepted 4, Grok Imagine accepted 3, and Recraft, Krea, and MAI Image accepted 1. Read GET /api/v1/images/models/{model}/endpoints for the current value.
Which image models can reply with both text and an image?
The models whose output modalities include text. On 11 September 2026 that was nine of the 52 image models on our catalog, all Gemini image models and OpenAI gpt-5-image models. Call them through POST /api/v1/chat/completions. In our test, google/gemini-3-pro-image returned text in 3 of 3 calls, openai/gpt-5-image in 2 of 3, google/gemini-3.1-flash-image in 1 of 4, and google/gemini-3.1-flash-lite-image in 0 of 2.
What image format does the Image API return?
It depends on the model. In our run, FLUX.2, Grok, and Seedream returned JPEG, OpenAI, Qwen, Microsoft, and Krea returned PNG, Sourceful and Recraft returned WebP, and recraft/recraft-v4.1-vector returned SVG. Twelve of the 52 catalog models accept an output_format parameter. Read the media_type field on each response rather than assuming a file extension.