> For the complete documentation index, see [llms.txt](https://docs.gpmautomate.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.gpmautomate.com/automate-en/action-guides/image-search/image-exists.md).

# Image exists

This action allows the tool to quickly "glance" at whether the target image is displayed on the screen or not. The immediate result returned is True (if found) or False (if not found).

* Difference: Unlike `Wait to image` (wait), this action does not pause to wait but only scans once at the time of execution.
* Effect: Very suitable for combining with conditional blocks (`If`, `Else if`), helping the script make smart decisions immediately (for example: if an ad pop-up is detected, close it; if not, proceed to the next step).

> ⚠️ Special note about Scale ratio: The percentage scale of the screen and the resolution of the browser when you take the sample image must be exactly the same as when the script runs in reality. If when taking the sample image you set the screen display to 100%, but when running the system profile it automatically opens at a scale of 80% or 125%, the image scanning algorithm will not be able to recognize the pixel structure of the target and will lead to incorrect results.

#### Real-life example: Check and close unexpected ad notifications (Popup)

When you browse a website, sometimes ad windows or unexpected survey notifications pop up, obscuring the screen. If there is an ad, the script needs to click the "X" button to close it before continuing; if not, the script will skip the closing step to avoid wasting time.

* Configuration method: You take a small sample image of the "X" button to close the ad for the system to recognize.
* Result: The system will scan the screen at that moment. If the "X" button appears, the output variable will receive the value `True`. You just need to combine it with the If conditional block (If variable = `True`) to call the Mouse click action at that position to clear the screen before proceeding.

> 💡 *Detailed parameters such as sample image area configuration (Image), color deviation (Threshold), True color, and output variable (Output) will be analyzed in depth in the guide to combine the trio of actions: Wait to image, Image exists, and Image search.*


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.gpmautomate.com/automate-en/action-guides/image-search/image-exists.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
