Dashral Pro is on the wayGet 30% off at launch

Dashral

Pricing calculatorPro

Slide to the team size and pick a plan, add-ons, billing and currency: the quote adds up line by line, with volume discounts, and the total counts to its new value.

When to use

  • A quote that adds up line by line: seats, plan, add-ons, billing and currency.
  • Per-seat and usage-based pricing, where the price depends on the buyer.

When not to use

  • Flat prices: Pricing tiers.
  • Enterprise deals priced in a conversation: a Talk to sales action.

Usage

Pricing calculator with your own data: every prop has the sample as its default, so pass only what you have.

example.tsx
import { PricingCalculator } from "@/components/dashral/blocks/pricing-calculator"

<PricingCalculator
  plans={plans}
  addOns={addOns}
  currencies={currencies}
  salesHref="/contact"
  onCheckout={(quote) => api.checkout.create(quote)}
/>

API reference

PricingCalculator

A pricing calculator: pick the team size (with volume discounts by bracket), a plan, add-ons, monthly or yearly and a currency, and the quote adds up line by line as you go — per seat, the volume discount, each add-on, the yearly saving and the total, which counts to its new value. Plans that don't fit the team size step aside. On phones the total rides along at the bottom. Every part comes from props: your plans, add-ons, brackets and currencies, and onCheckout gets the quote.

PropTypeDefault
eyebrowReact.ReactNode"Pricing"
titleReact.ReactNodesample
descriptionReact.ReactNodesample
plansCalculatorPlan[]sample
addOnsCalculatorAddOn[]sample
bracketsCalculatorBracket[]sample
currenciesRecord<string, CalculatorCurrency>

By currency code; the first is your base currency (rate 1).

sample
maxSeatsnumbersample
yearlyOffnumber

The share off when billed yearly.

0.2
initial{ seats: number; plan: string; billing: Billing; currency: string; addOns: string[] }sample
salesHrefstring

"Talk to sales" for teams past maxSeats.

"#"
onCheckout(quote: Quote) => void

The button under the quote, with the quote as it stands.

—

type Billing

= "monthly" | "yearly"

type CalculatorPlan

A plan, priced per seat a month (in your base currency); maxSeats makes it step aside for bigger teams.

PropTypeDefault
idstring—
namestring—
blurbstring—
perSeatnumber—
maxSeatsnumber—
featuresstring[]—
popularboolean—

type CalculatorAddOn

An add-on: a flat price a month, or a price per seat, or both; free with includedIn.

PropTypeDefault
idstring—
namestring—
detailstring—
flatnumber—
perSeatnumber—
includedInstring—

type CalculatorBracket

A volume bracket: seats from–to, and the share off each seat.

PropTypeDefault
fromnumber—
tonumber—
offnumber—
labelstring—

type CalculatorCurrency

A currency the quote can show in: its rate from your base currency, its locale, the unit lines round to, and cents.

PropTypeDefault
ratenumber—
localestring—
unitnumber—
centsboolean—

type Quote

The quote as it stands, for your checkout: every amount in the picked currency, a month.

PropTypeDefault
seatsnumber—
planCalculatorPlan—
addOnsCalculatorAddOn[]—
billingBilling—
currencystring—
lines{ seats: number; volumeOff: number; addOns: number; yearlyOff: number }—
perMonthnumber—