React Hero Section
HeroSection is a React hero section block that sets a display headline, a lede and calls to action over any backdrop, with a lit glass frame for a product shot and a logo strip. Use it as the first block of a landing page.
npx shadcn@latest add https://lokendra-builds.github.io/sheenui/r/hero-section.jsonNew: every block, light and dark
Interfaces that catch the light
A glass component library for React, built on Base UI, Tailwind v4 and Motion. Copy the source and make it yours.
HeroSectiondefaultHeroSectionLabels
Centered, over a scene
The background slot takes a SheenScene (or any image). The product shot sits in a glass frame with a pool of light under it. Wrap a phrase of the headline in <em> to light it with the accent.
New: every block, light and dark
Interfaces that catch the light
A glass component library for React, built on Base UI, Tailwind v4 and Motion. Copy the source and make it yours.
Trusted by teams at
- Alder
- Brightloom
- Cobalt
- Driftwood
- Evergreen
import { SheenScene } from "@/components/sheenui/backdrop/scene";
import { HeroSection } from "@/components/sheenui/blocks/hero-section";
// Package build (after the first npm release, or a packed tarball): import { HeroSection, SheenScene } from "@sheenui/theme";
// This example also uses backdrop: npx shadcn@latest add https://lokendra-builds.github.io/sheenui/r/backdrop.json
export function Example() {
return (
<HeroSection
headingLevel={1}
eyebrow="New: every block, light and dark"
title={<>Interfaces that <em>catch the light</em></>}
description="A glass component library for React, built on Base UI, Tailwind v4 and Motion. Copy the source and make it yours."
primaryAction={{ label: "Get started", href: "/docs/installation" }}
secondaryAction={{ label: "Browse components", href: "/components" }}
background={
<SheenScene
src="/scenes/studio-v2.webp"
avifSrc="/scenes/studio-v2.avif"
dim={0.75}
priority
/>
}
media={
<div className="grid aspect-[16/9] grid-cols-[28%_1fr] gap-3 p-3">
<div className="rounded-sheen-lg bg-sheen-hover" />
<div className="grid grid-rows-[auto_1fr] gap-3">
<div className="h-10 rounded-sheen-lg bg-sheen-hover" />
<div className="rounded-sheen-lg bg-sheen-hover" />
</div>
</div>
}
logos={[{ name: "Alder" }, { name: "Brightloom" }, { name: "Cobalt" }, { name: "Driftwood" }, { name: "Evergreen" }]}
/>
);
}Files to copy
7 folders · 11 files · 4 packages
- From
theme/src/ blocks/hero-section.tsxcomponents/button/components/spinner/hooks/{use-latest.ts, use-magnetic.ts, use-media-query.ts, use-preferences.ts}motion/{gate.ts, tokens.ts}lib/{cn.ts, form.ts, heading.ts, state-light.tsx}styles/
- shadcn CLI
npx shadcn@latest add https://lokendra-builds.github.io/sheenui/r/hero-section.jsonRegistry item: hero-section. The styles need the Tailwind v4 glass UI setup.- The examples also use
components/backdrop/scene.tsx
npx shadcn@latest add https://lokendra-builds.github.io/sheenui/r/backdrop.json- Packages
pnpm add @base-ui/react clsx motion tailwind-merge
Start-aligned, with the built-in aurora
align='start' puts the copy at the start edge and the media beside it. Leave background out for the aurora; the actions can be buttons (onClick) as well as links.
Ship the dashboard, not the plumbing
Charts, tables and forms that already agree on spacing, focus and motion.
import { HeroSection } from "@/components/sheenui/blocks/hero-section";
// Package build (after the first npm release, or a packed tarball): import { HeroSection } from "@sheenui/theme";
export function Example() {
return (
<HeroSection
align="start"
title="Ship the dashboard, not the plumbing"
description="Charts, tables and forms that already agree on spacing, focus and motion."
primaryAction={{ label: "Start a project", onClick: () => console.log("start") }}
secondaryAction={{ label: "Read the docs", href: "/docs/installation" }}
media={
<div className="grid aspect-[4/3] place-items-center p-6 text-sheen-fg-muted">Your product shot</div>
}
/>
);
}Props
HeroSectionLabels keys and English defaults (2)
Keyboard
Accessibility
- A <section> named by its headline (labels.region when headingLevel is 'none'). A landing page's hero is usually its h1: pass headingLevel={1}.
- The background (aurora or SheenScene) is aria-hidden; the logo strip is a list labelled by labels.logosTitle and every logo has a text name.
- Text and buttons rise by transform only; the frame fades in on itself. Reduced motion removes the movement.
- Keep the headline over a calm part of your scene and raise dim until the lede reads at 4.5:1 in both themes.
All exports on this page
HeroSection— A landing-page hero: a display headline, a lede, one or two calls to action, an optional product shot in a lit glass frame and a logo strip.defaultHeroSectionLabels— The English HeroSectionLabels used when labels is omitted; a partial labels prop is merged over it.
When to use the hero section
- Use HeroSection above the fold of a product launch or open-source landing page, over a gradient or photo backdrop, with a headline, one sentence of lede, a primary and a secondary action, and a product shot in a lit glass frame underneath.
- Use the background slot for a SheenScene or your own image when the page has a strong photographic mood, or leave it out for the built-in aurora drawn from the theme's token colours.
- Use align="start" to put the copy at the start edge and the media beside it on a wide block, which suits a product page with a real screenshot or a live demo.
- Skip it for a compact page header inside an app; a plain heading and a Button group are enough there, and the glass frame would compete with the content.
- Pair it with FeatureGrid and Testimonials below it, SiteFooter at the end, and AnnouncementBanner above it, which together make a complete marketing page.
Frequently asked questions
Related pages
20 blocks pages in all: browse them on All blocks.
By Lokendra Singh Rathore (GitHub, opens in a new tab). Published , updated .

