> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kiwify.com.br/llms.txt
> Use this file to discover all available pages before exploring further.

# is_preview

> The is_preview flag indicates whether the template is being rendered inside the editor or not.

You can use `is_preview` flag to add messages, placeholder content etc. inside a template or block when previewing the page inside the editor.

## Syntax

```liquid theme={null}
{% is_preview %}
```

## Scope

It's accessible globally, in any template, section or block.

<Frame>
  ```mermaid theme={null}
  graph TD
      A[Global Context] --> B[is_preview]
      style A fill:#f9f9f9,stroke:#333,stroke-width:2px,color:#333,stroke-dasharray: 5 5
      style B fill:#4B96FF,stroke:#333,stroke-width:1px,color:white,font-weight:bold
      linkStyle 0 stroke:#4B96FF,stroke-width:2px
  ```
</Frame>

## Example

<Columns cols={2}>
  <CodeGroup>
    ```liquid Code theme={null}
    {% if is_preview %}
    <p>This appears only inside the editor</p>
    {% endif %}
    ```
  </CodeGroup>

  <CodeGroup>
    ```liquid Output theme={null}
    <p>This appears only inside the editor</p>
    ```
  </CodeGroup>
</Columns>
