Components/GretTech/Pricing Switcher

Pricing Switcher

Pricing plans with a monthly/yearly switch, prices that roll like an odometer, a highlighted plan and stacked feature lists.

v0

Installation

Full Setup guide

Install the component automatically via Shadcn CLI.

npx shadcn@latest add https://www.grettech.com/api/registry/pricing-switcher

Props

PropTypeDefaultDescription
plans*
PricingPlan[]-The plans, in order. Two to four work best.
currency
string"USD"ISO 4217 currency code for prices.
locale
string"en-US"Locale used to format prices.
defaultBilling
"monthly" | "yearly""monthly"Billing period shown first.
billing
"monthly" | "yearly"-Controlled billing period.
onBillingChange
(billing: Billing) => void-Called when the visitor switches billing.
yearlyNote
string"Save 20%"Badge next to the yearly option. Pass an empty string to hide it.
popularBadge
string"Most popular"Badge on the popular plan.
linkAs
React.ElementType"a"Component used for links, e.g. next/link's Link. It receives href and className.
className
string-Extra classes for the root element.
...props
React.HTMLAttributes<HTMLDivElement>-Any other attributes, passed to the root element.