CrazyGLCrazyGLHomeExploreGitHubBrowse heroesLoading hero…← Back to gallery@crazygl/cursor-reveal-text

Cursor Reveal Text

Two stacked paragraphs — a primary line shown in the surface colour, and a secret reveal line shown only inside a cursor-following spotlight that grows on hover.

ReactInteractiveFont#cursor#reveal#spotlight#typography#interactive

Usage

import CursorRevealText from '@crazygl/hero-cursor-reveal-text';

export default function Page() {
  return (
    <CursorRevealText
      primaryText="I'm a selectively skilled product designer..."
      revealText="Crafting elegant solutions through code..."
      hoverSize={400}
    />
  );
}

Customise

  • ContentprimaryText, revealText.
  • SpotlightdefaultSize (resting diameter), hoverSize (diameter over text), cursorFollowSpeed (0.05 liquid → 1 snaps), transitionDuration (grow/shrink ease).
  • ColoursbgColor, textColor, revealBgColor, revealTextColor; pair contrasting hues for the strongest effect.
  • TypographyfontSize, lineHeight, maxWidth, headingFontFamily, headingFontWeight.

Best for

  • Portfolio bio and "about" sections with a hidden punchline
  • Agency / studio personality blocks and case-study intros
  • Interactive landing pages that reward cursor exploration
01 · Install the package

One command, zero config.

npm install @crazygl/hero-cursor-reveal-text
02 · Render the component

Import once, drop it in.

The component takes the same props you see in the live customizer on the right — every default ships poster-quality.

hero.tsx
import CursorRevealText from '@crazygl/hero-cursor-reveal-text';

export default function Landing() {
  return (
    <CursorRevealText />
  );
}
03 · Use it in a page

SSR-safe by default.

The wrapper renders static HTML on the server and only initialises the canvas after hydration, so search engines see your copy.

page.tsx
// app/page.tsx — works in SSR-first frameworks (Next, Remix, Astro, etc.)
'use client';

import CursorRevealText from '@crazygl/hero-cursor-reveal-text';

export default function Page() {
  return (
    <section>
      <CursorRevealText
        heading="Say hi."
        subheading="Your new hero."
      />
      <article>
        <h2>Welcome</h2>
        <p>Your content keeps its own voice below the hero.</p>
      </article>
    </section>
  );
}
You might also like

Similar heroes

Text Reveal Lens

A cursor-driven lens that reveals the bright real colour of a heading from underneath a dim default. Five lens shapes — circle, rectangle, diamond, wave, star — with an optional gradient fill on the revealed text.

Cursor Shadow Text

The heading casts a real drop shadow whose direction tracks the cursor — like a single fixed light moving across the room.

Text Reveal

Heading wiped in from a single direction via a hard clip-path mask, with a small per-letter delay — the foundational reveal everyone needs.

Text Hover Reveal

Each item shows a default heading; on hover the heading scrolls up and a secondary line scrolls in from below — list-of-services interaction.

Text Image Cursor

A list of items where hovering each row reveals a thumbnail that follows the cursor — case-study index pattern, magazine-grade.

Text Split Reveal

Heading splits into two halves that slide apart to reveal a secondary line between them — the curtain-pull pattern.
Live customizer

Cursor Reveal Text

Default size40pxHover size400pxCursor follow smoothing0.5Lower = laggy / liquid; higher = snaps to cursor.Grow / shrink duration0.5sBackgroundPrimary text colourReveal backgroundReveal text colourFont size36pxLine height1.3Max width1000pxFontWeight500InteractivityWhich input drives the hero — try Scroll if you want the page to drive motion.
CrazyGL · crazygl.comProgrammable hero sections for real websites.