---
title: "Text Split Headline"
description: "The words of a heading wait apart at different depths and slide together into one line as it scrolls to mid view."
url: https://gelatinui.com/components/text-split-headline
markdown_url: https://gelatinui.com/components/text-split-headline.md
access: pro
install: "npx shadcn@latest add @gelatin-ui-pro/text-split-headline"
version: "2026-11-14"
index: https://gelatinui.com/llms.txt
docs_index: https://gelatinui.com/docs/llms.txt
---

# Text Split Headline

> The words of a heading wait apart at different depths and slide together into one line as it scrolls to mid view.

Page: https://gelatinui.com/components/text-split-headline

## When to use it

Best for: A short headline of two to six words at the start of a section.

- Wrap the text of a heading. Every element is a `span`, so it is valid in an `h1` or `h2`.
- Use `spread` (in px, default 64) to set how far the words wait from the line at the edges of the pass.
- Use `seed` to pick another scatter. With no `seed`, the text picks its own, so one text always scatters the same way.
- Use `container` when the headline scrolls inside a box and not with the page, `disabled` to keep the line whole, and `locale` for the word breaks of a language.

## When not to use it

- For images and layers that move at their own speed as the page scrolls, use [Parallax](https://gelatinui.com/components/parallax.md).
- For a long headline or body text that people must read at once, use plain text.

## Notes for agents

- `children` must be a string. Each word is an inline box, and the root carries the text as its name, so a screen reader reads it once with its spaces. An `aria-label` prop wins.
- Each word moves on `translate`, `scale`, and `opacity` from a place set by the seed, so the server and the browser draw the same scatter. The line is whole from 0.38 to 0.62 of the pass.
- The first and last words move inward across, so they do not push past the edge of a narrow page. In right to left a `dir` on any parent mirrors the scatter.
- The words wrap as plain text. A word wider than the line breaks, so it does not scroll a phone page sideways.
- React does not render while the page scrolls. Off screen the words hold still. A `spread` or `seed` that is not a number takes the default.

## Anatomy

```text
TextSplitHeadline
```

## API reference

### TextSplitHeadline

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `locale` | `string` |  | The BCP 47 locale for the letter and word split (`Intl.Segmenter`). Default: the `DisplayLocaleProvider` locale, else `"en-US"`. |
| `children` | `string` |  | The headline text. |
| `spread` | `number` | SPLIT_HEADLINE_SPREAD | How far the words wait from the line at the edges of the pass, in px. Default 64. |
| `seed` | `number` |  | The seed of the scatter. Default: a hash of the text, so one text always scatters the same way. |
| `container` | `RefObject<HTMLElement \| null>` |  | The scroll box, when the headline scrolls inside one and not with the page. |
| `disabled` | `boolean` | false | Keeps the words in one line and stops the scroll work. |

### TextSplitHeadlineWord

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `progress` | `MotionValue<number>` |  |  |
| `sign` | `MotionValue<-1 \| 1>` |  |  |
| `far` | `SplitWordPlace` |  |  |
| `children` | `string` |  |  |

## Styling

| Part | Slot | States | CSS variables | Tokens |
| --- | --- | --- | --- | --- |
| TextSplitHeadline | `text-split-headline` |  |  |  |

## Usage

Wrap the headline of a section. Keep it short: two to six words.

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-pro/text-split-headline @gelatin-ui/button
```

```tsx title="features-section.tsx"
import { TextSplitHeadline } from "@/components/pro/text/text-split-headline";
import { Button } from "@/components/ui/button";

export function FeaturesSection() {
  return (
    <section className="mx-auto flex max-w-3xl flex-col items-center gap-6 px-4 py-40 text-center">
      <p className="font-mono text-xs tracking-widest text-muted-foreground uppercase">
        Why teams switch
      </p>
      <h2 className="text-6xl font-semibold tracking-tight text-balance max-sm:text-4xl">
        <TextSplitHeadline spread={64}>Every part falls into place</TextSplitHeadline>
      </h2>
      <p className="max-w-md text-muted-foreground">
        One set of tokens, one set of parts, and every screen drawn the same way.
      </p>
      <Button variant="outline">See how it works</Button>
    </section>
  );
}
```

## 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/text-split-headline
```

It adds 25 registry items: 24 files, 4161 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

- [Parallax](https://gelatinui.com/components/parallax.md)
- [Parallax Image](https://gelatinui.com/components/parallax-image.md)
- [Text Scroll Marquee](https://gelatinui.com/components/text-scroll-marquee.md)

## Motion

| Part | Motion |
| --- | --- |
| Scroll scatter | none · the words slide together into one line as the headline reaches the middle of the view, and part as it leaves, in the same frame as the scroll; the last px come slowly |
