# Background removal

{% hint style="info" %}
Background removal is powered by Visual Operations Credits; full details on consumption rates can be found here: [Visual Operation Credits table](https://docs.cloudimage.io/account-management/usage#visual-operation-credits-table)
{% endhint %}

<mark style="color:orange;">**bg\_remove=1**</mark>

Background removal automatically detects the foreground object and isolates it by removing the background of an image using advanced AI technology. It can help you create a solid or transparent background for your pictures. This can give your application or website an overall polished look. Moreover, product images with a clear-defined foreground can be indexed better in search engines which rely on AI classification.

{% hint style="info" %}
Please keep in mind that the background removal operation is asynchronous which means that the first request will return the original image (with short cache value) while the image is being processed in the background. The status is checked on each consecutive request and after the operation is complete, the origin image is replaced and the standard caching settings are set.
{% endhint %}

## Examples

| Preview                                                             | Syntax                                                                                                                                                                                                                                                                                     |
| ------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| <img src="/files/3yJZ3F0YIBRNBIJBatrn" alt="" data-size="original"> | [/samples.scaleflex.com/face.png?<mark style="color:orange;">**w=400**</mark>](https://doc.cloudimg.io/https://samples.scaleflex.com/face.png?w=400)                                                                                                                                       |
| <img src="/files/QqKswrOqjpAdmuG9j3MM" alt="" data-size="original"> | [/samples.scaleflex.com/face.png?<mark style="color:orange;">**w=400**</mark>&<mark style="color:orange;">**bg\_remove=1**</mark>](https://doc.cloudimg.io/https://samples.scaleflex.com/face.png?w=400\&bg_remove=1)                                                                      |
| <img src="/files/eKJADtzVpnSiHcat5KWh" alt="" data-size="original"> | [/samples.scaleflex.com/purse.jpg?<mark style="color:orange;">**w=400**</mark>](https://doc.cloudimg.io/https://samples.scaleflex.com/purse.jpg?w=400)                                                                                                                                     |
| <img src="/files/eav1XeQwbOq9APmSykK3" alt="" data-size="original"> | [/samples.scaleflex.com/purse.jpg?<mark style="color:orange;">**w=400**</mark>&<mark style="color:orange;">**bg\_remove=1**</mark>&<mark style="color:orange;">**bg\_color=456**</mark>](https://doc.cloudimg.io/https://samples.scaleflex.com/purse.jpg?w=400\&bg_remove=1\&bg_color=456) |

Feel free to try the background removal algorithm with your own images on our [AI demo page](https://ai.scaleflex.com/demo/#/).


---

# 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.cloudimage.io/transformations/image-operations/background-removal.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.
