# Text To Image API Pricing

As of October 10, 2026, Text To Image costs $0.052 per image on AI/ML API.

- Page: https://models.litellm.ai/models/text-to-image
- LiteLLM model name: `aiml/flux/kontext-pro/text-to-image`
- Added to LiteLLM: August 2025
- Prices updated: October 10, 2026

## Pricing by provider

Token prices in USD per 1M tokens.

| Provider | Model name | Input | Output | Cache read | Per image | Per second | Context |
|---|---|---|---|---|---|---|---|
| AI/ML API | `aiml/flux/kontext-pro/text-to-image` | – | – | – | $0.052 | – | – |
| AI/ML API | `aiml/flux/kontext-max/text-to-image` | – | – | – | $0.104 | – | – |

## Cost examples

Generating 1,000 images:

- AI/ML API: $52.00

## Use it with LiteLLM

```python
from litellm import image_generation

response = image_generation(
    model="aiml/flux/kontext-pro/text-to-image",
    prompt="A cute baby sea otter",
)
```

## FAQ

### How much does Text To Image cost?

Text To Image costs $0.052 per image on AI/ML API.

### Which providers offer Text To Image?

Text To Image is available from AI/ML API through LiteLLM, using the model name aiml/flux/kontext-pro/text-to-image.

### How do I call Text To Image with an OpenAI-compatible API?

Use the LiteLLM Python SDK with model="aiml/flux/kontext-pro/text-to-image", or add the model to the LiteLLM proxy's config.yaml and send requests to /v1/images/generations from any OpenAI client. LiteLLM tracks the cost of every request at the prices on this page.

### When did LiteLLM add Text To Image?

Text To Image was added to LiteLLM's model price file in August 2025.

Source: LiteLLM model price file, https://github.com/BerriAI/litellm/blob/main/model_prices_and_context_window.json
