shadcn.io is not affiliated with official shadcn/ui
Centered Single Price Display Hero Block for React
A compact centered hero that leads with its one price: a launch pill, a headline and a sentence, then the price in a hairline frame beside a Shine Button and three trust points.
Installation
Overview
A compact centered hero that leads with its price, for React with Base UI. A pill announces the new feature, then a headline and one sentence sit between solid page rails. Below them a hairline frame with + marks on its corners holds the plan: the oversized monthly price on one side and, across a divider, the Shine Button with three trust points. On a phone the price comes first and the button follows it, so the button stays on the first screen. It's built from Announcement, Badge, Status, Guides and Shine Button, with Lucide icons and Tailwind CSS, and the copy is for Tidyledger, a fictional bookkeeping app for freelancers. Each part fades in once with CSS, and nothing moves for visitors who ask for reduced motion. For SaaS products with one simple plan, subscriptions and any landing page where an honest price builds trust.
FAQ
How do I change the price and the billing period?
Edit the PRICE object at the top of the file: name is the plan's label above the figure, currency and amount make the big figure, unit is the short period shown beside it (/mo) and per is the word a screen reader hears instead ("per month"). For a yearly plan, set unit: "/yr" and per: "year". The currency is plain text before the number; for a locale that writes it after, move it in the markup. Keep the subtitle and the trust points in step with the plan.
How do I send the call to action to my checkout?
Point the Shine Button's link at your sign-up or checkout page, such as a Stripe or Paddle checkout URL, in place of #. It's a real link, so it opens in a new tab with a middle click and works before any JavaScript loads.
On Base UI, the button renders it with render={<a href="/checkout" />} and nativeButton={false}.
How is the price read by a screen reader?
As "$19 per month". The short /mo beside the figure is hidden from assistive technology, and a visually hidden "per month" says the period in words. The figure sits in a dir="ltr" span, so the currency stays before the number on right-to-left pages. The page has one h1, the pill is one link named by its sentence, and the trust points are a list whose check marks are decorative.
Why doesn't the price count up or roll?
Because it never changes. It renders as text on the server, so it's right before any script runs, and it only fades in once with the rest of the hero, with a CSS transition that's off under reduced motion. Counting a price up from zero would show visitors wrong prices on the way. If your plan has monthly and annual prices, the billing toggle hero rolls the figure when the visitor switches.
How does this teaser fit on a phone?
Below the md breakpoint the frame stacks: the price first, then, under a hairline, the button and the three trust points. The headline wraps, balanced, at text-4xl, and the price drops from text-6xl to text-5xl. The button spans the frame, and ends well within the first screen of a phone.
Related
- Pro
A centered single-plan hero with a monthly and annual switch under the headline, then one band split by a hairline: the price beside a Shine Button, and six included features.
- Pro
A centered pricing hero with Free and Pro side by side in one hairline band, the Pro cell tinted and holding the Shine Button, and a plan switch on phones.
- Pro
Centered ROI Calculator Hero
PricingA centered showcase hero with two actions over a framed calculator: a team-size slider beside an estimate of the annual savings, which rolls to each new figure.
- Pro
Centered Minimal Hero
Type and motionA compact centered type-only hero: a two-line headline with a muted second line, one sentence, a Shine Button and a second action, on faded rails.
- Pro
Centered Inline Email Signup Hero
Signup and waitlistA short centered waitlist hero with an email field and a Shine Button on one row inside a framed box, a confirmation in place, an avatar row and two trust points.
- Pro
Hero With Stats
Stats and live dataA split hero with a headline, a Shine Button and a second action beside a rail of four key figures on shared hairlines, each with its period and a small bar trend.