# How to create sticker images

Stickers are small background-less images that users can use, for example, to react in a conversation or to decorate their profile page:

<figure><img src="/files/Dlhn14R0HlSXabPoc5lb" alt="" width="563"><figcaption></figcaption></figure>

The Photoroom API makes it easy to add this feature to your app.&#x20;

Here's a before/after example of the kind of high-quality sticker the API can create:

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

There are two different ways to create a sticker through the Photoroom API, depending on whether the image you want to process is stored locally (in a file or a temporary variable) or hosted remotely.

## Case 1: the orginal image is stored locally

If the image you want to process is stored locally, you can turn it into a sticker by calling our [Remove Background API](/remove-background-api-basic-plan/quickstart-guide.md).

Here's how the call looks like:

```bash
curl --request POST \
  --url https://sdk.photoroom.com/v1/segment \
  --header 'x-api-key: YOUR_API_KEY' \
  --form 'image_file=@/absolute/path/to/image.jpg' \
  --form 'crop=true' \
  --output sticker.png
```

{% hint style="info" %}
If you don't have an API key, here are the [steps to create yours](/getting-started/introduction.md#how-can-i-get-my-api-key).
{% endhint %}

Notice how, additionally to sending the `image_file`, we also set the argument `crop=true`.

As its name suggests, this argument crops the size of the result image to that of the cutout subject.

## Case 2: the original image is hosted remotely

If the image you want to process is stored remotely, you can turn it into a sticker using the [Image Editing API](/image-editing-api-plus-plan/quickstart-guide.md).

Here's how the call looks like:

```bash
curl --request GET \
  --url 'https://image-api.photoroom.com/v2/edit?background.color=transparent&background.scaling=fill&outputSize=croppedSubject&imageUrl=IMAGE_URL_GOES_HERE' \
  --header 'x-api-key: API_KEY_GOES_HERE' \
  --output sticker.png
```

{% hint style="info" %}
If you don't have an API key, here are the [steps to create yours](/getting-started/introduction.md#how-can-i-get-my-api-key).
{% endhint %}

Notice how the URL of the image is passed through the query string argument `imageUrl`.

This URL must be accessible publicly over the Internet.

{% hint style="warning" %}
Make sure to [URL encode](https://www.w3schools.com/tags/ref_urlencode.ASP) the value you set for the argument `imageUrl`.
{% endhint %}

## Conclusion

As we’ve seen, the Photoroom API makes it easy to create high-quality stickers, whether the image that you want process is stored locally or remotely.

Please note that there's no difference in quality between the two approaches: both will yield the exact same cutout of the subject.


---

# 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/tutorials/how-to-create-sticker-images.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.
