---
title: "Cloud Sea Background"
description: "A slow flight over a sea of lit clouds; the time of day sets the light."
url: https://gelatinui.com/components/cloud-sea-background
markdown_url: https://gelatinui.com/components/cloud-sea-background.md
access: free
install: "npx shadcn@latest add @gelatin-ui/cloud-sea-background"
registry_item: https://gelatinui.com/r/cloud-sea-background.json
version: "2026-11-24"
index: https://gelatinui.com/llms.txt
docs_index: https://gelatinui.com/docs/llms.txt
---

# Cloud Sea Background

> A slow flight over a sea of lit clouds; the time of day sets the light.

Page: https://gelatinui.com/components/cloud-sea-background

## When to use it

Best for: A travel or calm brand hero: a slow flight over lit clouds, in the light of the local time.

- Use `at` with a fixed `Date` (a booking time, a story) to show that light. The default is the local time now, read once a minute.
- Use `cover` (0 to 1) for how much of the sea is cloud, and `fly` for the flight speed.
- Use `mask` (`top`, `bottom`, `edges`, or `radial`) to fade an edge into the page, and `maskSoftness` for the width of the fade.

## When not to use it

- For a flight over lit hills, use [Terrain Flyover Background](https://gelatinui.com/components/terrain-flyover-background.md).
- For aurora curtains of fine threads, use [Aurora Strands Background](https://gelatinui.com/components/aurora-strands-background.md).

## Notes for agents

- With no `palette`, each part of the day (night, dawn, day, dusk) has its own palette, and a change eases in. A `palette` you pass replaces them.
- `pointer` is on by default.
- Children sit on top of the moving picture. The root is `relative isolate overflow-hidden`: give it a height, or let a flex parent size it.
- `palette` takes CSS colors: the ground, the second ground, then the look colors. The default palette has its own light and dark values.
- It stops off screen and in a hidden tab. `paused` holds the frame, and `speed={0}` shows a still frame.
- With no WebGL2 the box stays empty. Set `fallback` to show a CSS gradient of the palette there, on the server, and before the first frame.

## Anatomy

```text
CloudSeaBackground
```

## API reference

### CloudSeaBackground

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `palette` | `readonly string[]` |  | Any CSS colors (`var(--token)` too): the ground, the second ground, then the look colors. |
| `speed` | `number` |  | The time scale: 1 (default) is the designed speed, 0 a still frame. |
| `paused` | `boolean` |  | True holds the current frame. Default false. |
| `trigger` | `BackgroundTrigger` |  | When it moves: `loop` (default) or `hover`. It draws its first frame either way. |
| `seed` | `number` |  | Another seed gives another field of the same look. Default 0. |
| `press` | `boolean` |  | True: a press on the box sends a ripple through the field where it lands; a press on a button or a link inside does not. Default false. |
| `pointer` | `boolean` | true | True: the field leans toward a mouse or pen over the box. Default false. |
| `fps` | `number` |  | The most frames a second. Default: the display rate. |
| `resolution` | `number` |  | A last scale on the canvas pixels, after the caps (0.5 draws a quarter of them). Default 1. |
| `mask` | `"bottom" \| "edges" \| "none" \| "radial" \| "top"` |  | Fades an edge into the page: `radial`, `edges`, `top`, or `bottom`. Default `none`. |
| `vignette` | `number` |  | Darkens toward the corners, 0 to 1. Default 0. |
| `fallback` | `boolean` |  | True: a CSS gradient of the palette shows on the server, until the first WebGL frame, and with no WebGL. Default false: the box stays empty and the live picture fades in, because the gradient looks unlike the real effect and the swap reads as a glitch. |
| `cover` | `number` | 0.55 | How much of the sea below is cloud. From 0 to 1. Default 0.55. |
| `fly` | `number` | 0.3 | How fast the view flies over the clouds. From 0 to 1. Default 0.3. |
| `toneLow` | `number` | 0 | The field light that reads as no tone. From 0 to 1. Default 0. |
| `toneHigh` | `number` | 1 | The field light that reads as full tone. From 0 to 1. Default 1. |
| `maskSoftness` | `number` | 0.25 | The share of the box the mask fade takes, from 0.05 to 0.6. Default 0.25. |
| `at` | `Date` |  | A fixed time to show (a booking time, a story). Default: the local time now, once a minute. |

## Styling

| Part | Slot | States | CSS variables | Tokens |
| --- | --- | --- | --- | --- |
| CloudSeaBackground | `cloud-sea-background` |  | `--cloud-sea-dawn-bg`, `--cloud-sea-dawn-bg-2`, `--cloud-sea-dawn-color-1`, `--cloud-sea-dawn-color-2`, `--cloud-sea-dawn-color-3`, `--cloud-sea-day-bg`, `--cloud-sea-day-bg-2`, `--cloud-sea-day-color-1`, `--cloud-sea-day-color-2`, `--cloud-sea-day-color-3`, `--cloud-sea-dusk-bg`, `--cloud-sea-dusk-bg-2`, `--cloud-sea-dusk-color-1`, `--cloud-sea-dusk-color-2`, `--cloud-sea-dusk-color-3`, `--cloud-sea-night-bg`, `--cloud-sea-night-bg-2`, `--cloud-sea-night-color-1`, `--cloud-sea-night-color-2`, `--cloud-sea-night-color-3` |  |

## Usage

Put the hero content inside as children: they sit on top of the moving picture. Give the root a height.

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

```bash
npx shadcn@latest add @gelatin-ui/cloud-sea-background @gelatin-ui/button
```

```tsx title="cloud-sea-hero.tsx"
import { CloudSeaBackground } from "@/components/backgrounds/cloud-sea-background";
import { Button } from "@/components/ui/button";

export function CloudSeaHero() {
  return (
    <CloudSeaBackground
      cover={0.6}
      className="flex h-[560px] flex-col items-center justify-center gap-6 px-6 text-center"
    >
      <p className="text-sm text-muted-foreground">Flights to Lisbon from €89</p>
      <h1 className="max-w-2xl text-5xl font-light tracking-tight">
        Above the clouds by breakfast
      </h1>
      <p className="max-w-md text-muted-foreground">
        Direct flights every morning from twelve cities.
      </p>
      <Button size="lg">Find flights</Button>
    </CloudSeaBackground>
  );
}
```

## 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/cloud-sea-background
```

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

## 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

- [Terrain Flyover Background](https://gelatinui.com/components/terrain-flyover-background.md)
- [Aurora Strands Background](https://gelatinui.com/components/aurora-strands-background.md)
- [Spiral Galaxy Background](https://gelatinui.com/components/spiral-galaxy-background.md)

## Motion

| Part | Motion |
| --- | --- |
| Show | chart · 600ms · ease-panel · the picture fades in after its first drawn frame |
| Loop | progress · the picture moves on its own clock at one speed; `speed` scales it, and 0 shows a still frame |
