Skip to main content
Accept donations with preset amount buttons and custom input.

Enable Donation Mode

Set checkoutMode to "donation" when creating a session.
Tax Exempt: Donation mode is automatically tax-exempt. No tax will be calculated or charged on donations—this is standard for charitable contributions.
Note: You don’t need to specify amount – the donor chooses the amount on the checkout page.
Donation mode cannot be combined with items array. The API will reject requests that include both checkoutMode: "donation" and an items array.

Donation Config Options

Validation:
  • presets must be within the minAmount-maxAmount range
  • defaultAmount must be within the minAmount-maxAmount range
  • Custom input is limited to 9 characters

Styling

Use the same appearance object as standard checkout (colors, fonts, radius, etc.); values apply via shared CSS variables on the page. See Customize Appearance.

What the Donor Sees

  1. Preset buttons for quick selection (e.g., $10, $25, $50, $100)
  2. “Other” option to enter a custom amount (if enabled)
  3. Standard payment form
  4. “Donate” button

Example: Simple Preset

Donor sees three buttons: $5, $10, $25

Example: Monthly Campaign

Donor sees $25, $50 (pre-selected), $100, $250, and “Other” option.

Example: With Min/Max Limits

  • Donors can enter any custom amount between $5 and $10,000
  • If they try to enter less than $5, they see: "Donation must be at least $5.00”
  • If they try to enter more than $10,000, they see: "Donation cannot exceed $10,000.00”
Create a shareable donation link via POST /api/payment-links/create:
Share the resulting url on social media, email campaigns, or your website. See Payment Links for full details.