# \[Preview] AI Upscale

<figure><img src="/files/iPYkGIdrFO8tJ8YYYtZD" alt=""><figcaption></figcaption></figure>

{% hint style="warning" %}
Warning: AI Upscale is available as a preview feature.

As such, please be aware that there could be breaking changes with a 2-week notice period.
{% endhint %}

## Overview

The Image Editing API allows you to upscale an input image.

AI Upscale increases the resolution of your input image by 4.&#x20;

For example, if you send an input image with resolution 300x400, then AI Upscale will turn it into an image of resolution 1200x1600.

{% hint style="info" %}
Please note that AI Upscale is currently limited to images with a maximum resolution of:&#x20;

* 1,000x1,000 pixels for the mode `ai.fast`
* 512x512 for the mode `ai.slow`
  {% endhint %}

Three upscale modes are available:

* Fast mode (classic)
* Fast mode (early access to new model using a header flag)
* Slow mode

In general, slow mode should produce results of a higher quality than fast mode.

However, we do recommend that you try all modes: for specific type of images, one might give better results than the other.

To upscale an image, set the argument `upscale.mode` to the value `ai.fast` or `ai.slow`.&#x20;

To test the new `ai.fast` model, additionally set the HTTP header `pr-ai-upscale-model-version` to `ai-upscale-2025-07-29`:

<table data-header-hidden><thead><tr><th align="center"></th><th align="center"></th><th width="250" align="center"></th><th></th></tr></thead><tbody><tr><td align="center"><em>(original image)</em></td><td align="center"><code>upscale.mode=ai.fast</code></td><td align="center"><code>upscale.mode=ai.slow</code></td><td><code>upscale.mode=ai.fast</code><br><em>Early access to new model</em></td></tr><tr><td align="center"><img src="/files/hCHD4Qz4rUV7YiD5K4C3" alt=""></td><td align="center"><img src="/files/aRXc5qXwvTGqksNlQ5o8" alt=""></td><td align="center"><img src="/files/bVXM5x8hwl4RHJHkbIII" alt=""></td><td><div><figure><img src="/files/cV3zqJpD5x8jg7pU8kBB" alt=""><figcaption></figcaption></figure></div></td></tr></tbody></table>

If you want to give it a try, here are the code snippets to reproduce the examples above:

```bash
curl --request POST \
  --url https://image-api.photoroom.com/v2/edit \
  --header 'x-api-key: YOUR_API_KEY' \
  --form 'imageFile=@"/path/to/image.jpeg"' \
  --form 'referenceBox="originalImage"' \
  --form 'removeBackground="false"' \
  --form 'upscale.mode="ai.fast"' \
  --output result-ai-fast.png
```

<a href="https://try-api.photoroom.com/?referenceBox=originalImage&#x26;removeBackground=false&#x26;upscale.mode=ai.fast" class="button primary">Try it now!</a>

```bash
curl --request POST \
  --url https://image-api.photoroom.com/v2/edit \
  --header 'x-api-key: YOUR_API_KEY' \
  --form 'imageFile=@"/path/to/image.jpeg"' \
  --form 'referenceBox="originalImage"' \
  --form 'removeBackground="false"' \
  --form 'upscale.mode="ai.slow"' \
  --output result-ai-slow.png
```

<a href="https://try-api.photoroom.com/?referenceBox=originalImage&#x26;removeBackground=false&#x26;upscale.mode=ai.slow" class="button primary">Try it now!</a>

```bash
curl --request POST \
  --url https://image-api.photoroom.com/v2/edit \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'pr-ai-upscale-model-version: ai-upscale-2025-07-29' \
  --form 'imageFile=@"/path/to/image.jpeg"' \
  --form 'referenceBox="originalImage"' \
  --form 'removeBackground="false"' \
  --form 'upscale.mode="ai.fast"' \
  --output result-ai-fast.png
```

<a href="https://try-api.photoroom.com/?pr-ai-upscale-model-version=ai-upscale-2025-07-29&#x26;referenceBox=originalImage&#x26;removeBackground=false&#x26;upscale.mode=ai.fast" class="button primary">Try it now!</a>

## Additional Examples

Below you can find some additional examples of using AI Upscale, with different type of images:

{% hint style="info" %}
Make sure to click on the images to see them in full resolution.
{% endhint %}

| *(original image)*               |      `upscale.mode=ai.fast`      |      `upscale.mode=ai.slow`      |            <p><code>upscale.mode=ai.fast</code><br><em>Early access to new model</em></p>           |
| -------------------------------- | :------------------------------: | :------------------------------: | :-------------------------------------------------------------------------------------------------: |
| ![](/files/vfN3HmuSP2gq6zb213w7) | ![](/files/4MI9HmmPeml2FBWWYqlQ) | ![](/files/kVIX4Su5UYgExWQ0NtqE) | <div><figure><img src="/files/LaLdcTZg3hAeWi5NfDqG" alt=""><figcaption></figcaption></figure></div> |
| ![](/files/f08uy6c6JlIDBukf4Qcw) | ![](/files/fFeSbxYFBfrmRQnzxOyE) | ![](/files/YjhobM6y6ksKRD15mI92) | <div><figure><img src="/files/tkkGVSgjHovFRVAnI24F" alt=""><figcaption></figcaption></figure></div> |
| ![](/files/j2pgggAPTQh9i5Oxyewu) | ![](/files/FtZwEx7Nn3nqs5nUlpAO) | ![](/files/N5XcBOVgDk7Ux9ZUG4ct) | <div><figure><img src="/files/lXsqbt2l2FoTfrCNG4MI" alt=""><figcaption></figcaption></figure></div> |
| ![](/files/SImlXd4LJBXFNuLsPIMG) | ![](/files/p1bEHuHGOiCClf84lPU5) | ![](/files/Yrhv7HqzWtCZuOhAoP5T) | <div><figure><img src="/files/BGnowoJ2yXrBnMOmfy4p" alt=""><figcaption></figcaption></figure></div> |
| ![](/files/T4snCXBcDnxlJRGmuvj4) | ![](/files/gUVqdTHb7Cyv7v4bObXV) | ![](/files/Fd4RqJIcRZhIg0badEKf) | <div><figure><img src="/files/haXSz0kYm0TLrL4pc5K9" alt=""><figcaption></figcaption></figure></div> |
| ![](/files/9WYbIUexMIIjX2qFxzhE) | ![](/files/3QOHKUq7pYighaORTTLq) | ![](/files/hsQTw3FxmdK37aQBYHRg) | <div><figure><img src="/files/hp5GFE7LeRRUn0GhojsV" alt=""><figcaption></figcaption></figure></div> |
| ![](/files/Pi6VDPugsyiNdxLLoG7Q) | ![](/files/edEgVTE0iRAPxzYbNODp) | ![](/files/HH2368TIaRTEChr40vEP) | <div><figure><img src="/files/HRAKBN7zR53VViL1gkx5" alt=""><figcaption></figcaption></figure></div> |
| ![](/files/ZKQkIHYWUeRMBkhVNWBn) | ![](/files/y4zvQIA5avT61dLIatXV) | ![](/files/QoDS2IOyrv6NsluSztCu) | <div><figure><img src="/files/LPFA7ofLBk3b4TyYRTbc" alt=""><figcaption></figcaption></figure></div> |

## Advanced Upscaling Model

For the most demanding use cases, an advanced model is available for Enterprise plans:

<div><figure><img src="/files/PR07kkvaYHiShRUcuLHR" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/ans0knVVgXBL6itaSmSL" alt=""><figcaption><p><em>(advanced model output)</em></p></figcaption></figure></div>

<div><figure><img src="/files/7IrWoNyTxUUt5Zdwfdqp" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/11BSRcj4fdsgqkcDLGlK" alt=""><figcaption><p><em>(advanced model output)</em></p></figcaption></figure></div>

<div><figure><img src="/files/0NbthCyBNnTBb9B4VmTU" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/DfwvmWm5MsjgUqznn6qH" alt=""><figcaption><p><em>(advanced model output)</em></p></figcaption></figure></div>

<div><figure><img src="/files/lvKhK5eYWcWnF2jw0c5m" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/PqNi7eQaVz15WMbXRXKw" alt=""><figcaption><p><em>(advanced model output)</em></p></figcaption></figure></div>

<div><figure><img src="/files/2K3Dq9aCpU02TckLvSxS" alt=""><figcaption><p><em>(original image)</em></p></figcaption></figure> <figure><img src="/files/wVhcCmCvXSKyC9hZrPJq" alt=""><figcaption><p><em>(advanced model output)</em></p></figcaption></figure></div>

{% hint style="info" %}
Make sure to click on the images to see them in full resolution.
{% endhint %}

If you're interested to use this advanced model, please [contact our team to book a demo](https://www.photoroom.com/contact-sales?utm_source=apidocumentation\&utm_medium=enterprisegated).

<a href="https://www.photoroom.com/contact-sales?utm_source=apidocumentation&#x26;utm_medium=enterprisegated" class="button primary">Book a demo</a>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.photoroom.com/image-editing-api-plus-plan/preview-ai-upscale.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
