# Layerize Text API

Ideogram publishes a public search API over its indexed pages; the guide is at https://ideogram.ai/agents/agent-access.

Source: https://ideogram.ai/features/text-layers/api/
Source observed: 2026-11-05T01:06:06.375Z
Last checked: 2026-11-15T16:35:40.029+00:00
Indexed: 2026-11-05T01:32:24.219+00:00

---

# Layerize Text API

We provide an API that detects visible text in an image and returns a clean base image with the detected text removed. You can upload branded assets, marketing materials, generated designs, photos, screenshots, product packaging, or other artwork, then overlay replacement text in any font, size, or language.

## Workflow

1. Upload an image.
2. Receive a text-free base image.
3. Overlay your own text.

## Endpoint reference

| Endpoint | Method | Description |
|---|---|---|
| `/v1/ideogram-v3/layerize-text` | `POST` | Extract text layers from an image |

### Request

Send the image as `multipart/form-data`.

| Parameter | Type | Required | Description |
|---|---|---:|---|
| `image` | binary | Yes | Image to analyze. Accepted formats are JPEG, PNG, and WebP; maximum size is 10 MB. |
| `prompt` | string | No | Description of the image. This improves detection accuracy and is auto-generated when omitted. |
| `seed` | integer | No | Random seed for reproducible results. |

### Response

| Field | Type | Description |
|---|---|---|
| `base_image_url` | string | URL of the image with all detected text removed. |
| `original_image_url` | string \| null | URL of the original image with its text intact. |
| `seed` | integer | Seed used for the layerization. |

## Layerize an image

The image must be sent as `multipart/form-data`. Each image may be up to 10 MB, and the accepted formats are JPEG, PNG, and WebP.

```python
import requests

# Upload your image directly
with open("poster.png", "rb") as f:
  response = requests.post(
    "https://api.ideogram.ai/v1/ideogram-v3/layerize-text",
    headers={"Api-Key": "<apiKey>"},
    files={"image": ("poster.png", f, "image/png")},
    data={"prompt": "A concert poster with event details"}
  )

layers = response.json()
print(f"Base image (text removed): {layers['base_image_url']}")
```

## Use the output

The response includes a base image with text removed and the original image for reference. Use the base image as a background and add replacement copy with a compositing tool such as Pillow or Cairo. This supports localization, A/B testing copy, and repurposing designs across campaigns.

```python
# Example response
{
  "base_image_url": "https://ideogram.ai/assets/image/...",
  "original_image_url": "https://ideogram.ai/assets/image/...",
  "seed": 42
}

# Download the base image for compositing
base_img = requests.get(layers["base_image_url"]).content
with open("base_no_text.png", "wb") as f:
  f.write(base_img)

# Now overlay your own text using Pillow, Cairo, or any compositing tool
```

## Combine with Generate

You can generate a design first and then send it to Layerize Text when you want us to handle the visual design while you replace the copy afterward.

```python
# Generate a design
gen = requests.post(
  "https://api.ideogram.ai/v1/ideogram-v3/generate",
  headers={"Api-Key": "<apiKey>"},
  data={
    "prompt": "A travel poster with the text 'Visit Tokyo'",
    "aspect_ratio": "2:3"
  }
).json()

# Download and layerize
img_data = requests.get(gen["data"][0]["url"]).content
layers = requests.post(
  "https://api.ideogram.ai/v1/ideogram-v3/layerize-text",
  headers={"Api-Key": "<apiKey>"},
  files={"image": ("design.png", img_data, "image/png")}
).json()

# base_image_url now has the design without text
print(layers["base_image_url"])
```

## Tips

- We can process images with text whether they are uploaded photos, screenshots, branded assets, or AI-generated designs; they do not need to come from Ideogram.
- Pass a short prompt describing the image to improve detection accuracy and help distinguish text from visual elements.
- Set a seed when you need reproducible results. The same image and seed produce the same output.
- For localization, layerize once and overlay translated copy in any language without regenerating the design.

## Related links

- [API](https://ideogram.ai/api-learn/)
- [API Pricing](https://ideogram.ai/pricing/?pricing_tab=api)
- [API Docs](https://developer.ideogram.ai/ideogram-api/api-overview)
- [API Status](https://status.ideogram.ai/)
- [Privacy Policy](https://ideogram.ai/legal/privacy/)

---

[Read this page’s summary](https://ideogram.ai/agents/api/public/v1/page-tldr?url=https%3A%2F%2Fideogram.ai%2Ffeatures%2Ftext-layers%2Fapi%2F&trace=t_380edc68d53d)

## Ask a follow-up about this page

Need a more specific answer? Ask the exact question you have. It returns a fresh, cited answer from Ideogram’s knowledge base. No account or API key required.

Open this URL with your own question, URL-encoded. Include your question in q. All research inputs are optional; no account or setup.

`GET https://ideogram.ai/agents/agent/faq?q={question}&trace=t_380edc68d53d`

[Tool guide and examples](https://ideogram.ai/agents/agent-access) · [OpenAPI](https://ideogram.ai/agents/api/public/v1/openapi.json) · [Page TLDR form](https://ideogram.ai/agents/agent-tools/page-tldr?url=https%3A%2F%2Fideogram.ai%2Ffeatures%2Ftext-layers%2Fapi%2F). Opening a form does not execute a tool.