---
title: "Mask Reveal"
description: "A circle, an arch, a burst, or giant text that opens like a window as the page scrolls, until the picture behind fills the view."
url: https://gelatinui.com/components/mask-reveal
markdown_url: https://gelatinui.com/components/mask-reveal.md
access: pro
install: "npx shadcn@latest add @gelatin-ui-pro/mask-reveal"
version: "2026-11-10"
index: https://gelatinui.com/llms.txt
docs_index: https://gelatinui.com/docs/llms.txt
---

# Mask Reveal

> A circle, an arch, a burst, or giant text that opens like a window as the page scrolls, until the picture behind fills the view.

Page: https://gelatinui.com/components/mask-reveal

## When to use it

Best for: A pinned hero where one shape or word opens like a window on a full photo as the page scrolls.

- Put an `Image` with `fill` (or a video) in `MaskRevealMedia`, and the window in `MaskRevealWindow`.
- Pick the window with `variant`: `circle`, `arch`, `burst`, or `text` (the text of its children).
- For a text window, set `origin` on a thick letter stroke, so the stroke fills the view.
- Put the real heading in `MaskRevealContent`: the window is decoration.
- In a scroll box, pass `container` and give the box `[container-type:size]`.

## When not to use it

- For a photo that only moves slower than the page, use [Parallax Image](https://gelatinui.com/components/parallax-image.md).
- For layers that move at their own speeds, use [Parallax](https://gelatinui.com/components/parallax.md).

## Notes for agents

- The root pins for 2.5 views (`range="pin"`); set another height with `className`.
- The window grows on a log scale over the first 80% of the pin, and the page color fades out over the last 15% of the growth.
- Default growth: circle 10, arch 14, burst 13, text 60. Raise `growth` for a smaller window.
- Heights and window sizes are in `cq` units: they follow a size container, else the screen.
- `disabled` shows the full photo, one view tall, with the content on a soft dark scrim.
- It moves with `transform` and `opacity` only, and the work stops off screen.

## Anatomy

```text
MaskReveal
├─ MaskRevealMedia (0..n)
├─ MaskRevealWindow (0..n)
└─ MaskRevealContent (0..n)
```

## API reference

### MaskReveal

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `container` | `RefObject<HTMLElement \| null>` |  | The scroll box, when the item scrolls inside one and not with the page. |
| `disabled` | `boolean` | false | Rests every layer and stops the work. |

### MaskRevealMedia

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `zoom` | `number` | 0.15 | How much larger the picture is at the start: 0.15 is 15%. It settles to 1. Default 0.15. |

### MaskRevealWindow

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `variant` | `"arch" \| "burst" \| "circle" \| "text"` | "circle" | The window: `circle` (default), `arch`, `burst`, or `text` (the text of the children). |
| `growth` | `number` |  | How many times larger the window is at the end of the growth. Default per variant: circle 10, arch 14, burst 13, text 60. |
| `origin` | `readonly [number, number]` |  | The point the window grows from, as shares of its box (`[0.5, 0.5]` is the middle). For a text, put it on a thick letter stroke, not in a gap or a letter hole. Not mirrored in right to left: it is a place on the outline. |
| `outlined` | `boolean` | false | Draws a thin line on the window edge at the start; it fades out as the window grows. |
| `children` | `string` |  | With `variant="text"`: the text of the window (the brand name). Plain text only. |

### MaskRevealContent

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `children` | `ReactNode` |  |  |
| `fade` | `boolean` | true | Fades the content out over the first 25% of the pin. Default true. |

## Styling

| Part | Slot | States | CSS variables | Tokens |
| --- | --- | --- | --- | --- |
| MaskReveal | `mask-reveal` | `data-disabled` | `--parallax-pin-top`, `--parallax-view` |  |
| MaskRevealMedia | `mask-reveal-media` | `data-disabled` |  |  |
| MaskRevealWindow | `mask-reveal-window` |  |  |  |
| MaskRevealContent | `mask-reveal-content` | `data-disabled` |  |  |

## Usage

Put the photo, the window, and the heading in the root.

The sample also uses `image`, which this add does not write. One command adds them with this item:

```bash
npx shadcn@latest add @gelatin-ui-pro/mask-reveal @gelatin-ui/image
```

```tsx title="brand-hero.tsx"
import {
  MaskReveal,
  MaskRevealContent,
  MaskRevealMedia,
  MaskRevealWindow,
} from "@/components/pro/effects/mask-reveal";
import { Image } from "@/components/ui/image";

export function BrandHero() {
  return (
    <MaskReveal>
      <MaskRevealMedia>
        <Image src="/fjord.webp" alt="A fjord at dawn" fill />
      </MaskRevealMedia>
      <MaskRevealWindow variant="text" origin={[0.47, 0.5]}>
        NORTH
      </MaskRevealWindow>
      <MaskRevealContent className="self-end pb-12">
        <h1>North Expeditions</h1>
      </MaskRevealContent>
    </MaskReveal>
  );
}
```

## Compose

Rules:

- Compose the parts (`compose-parts`): Build each item from its named parts as children, and pass your text and icons in as parts.
- Every state is designed (`every-state`): Give each view of data its loading, empty, and error states: a skeleton in the final layout, an `Empty` with an illustration and one next action, and an error that says what failed and how to retry.

## Add it

```bash
npx shadcn@latest add @gelatin-ui-pro/mask-reveal
```

It adds 27 registry items: 26 files, 4300 lines, and the npm packages `@base-ui/react`, `@mantine/hooks`, `clsx`, `motion`, `tailwind-merge`, `tailwind-variants`.

## Built on

- [Parallax](https://gelatinui.com/components/parallax.md)

## For AI agents

- Every item, one file: https://gelatinui.com/llms.txt
- MCP server (`search_items`, `get_item`, `get_install_plan`): https://gelatinui.com/mcp

## Related

- [Parallax](https://gelatinui.com/components/parallax.md)
- [Parallax Image](https://gelatinui.com/components/parallax-image.md)
- [Image](https://gelatinui.com/components/image.md)

## Keyboard

| Keys | Action |
| --- | --- |
| Tab | Moves into the content. When the content has faded, the page jumps back to the start of the pin. |

## Accessibility

The window is hidden from screen readers. Give the real name as a heading in `MaskRevealContent`.

The photo keeps its `alt`.

## Motion

| Part | Motion |
| --- | --- |
| Window | none · the window grows with the scroll in the same frame, one ratio per frame, with no easing |
| Content | none · the content fades out over the first 25% of the pin |
