NextFire main logoNextFire
Docs X
Introduction
Get Started
Clone repo
Run the app
Configuration
Firebase
Create firebase app
Authentication
Firestore
Storage
Functions
Global configuration
Public
Site config
Payments
Stripe
One time
Subscriptions
Webhooks
Usage
Project structure
Static pages
Public pages
Protected pages
Auth
Client auth
Server auth
Data fetching
Firestore client
Firestore admin
Functions
Storage
Content
Blog
Documentation
Components
Markdown
Cards
Diagrams
Filetree
Lists
Maths
Notes
Steps
Table
Tabs
Public
Deep
Deeper
Even deeper
  1. Payments
  2. More
  3. One Time

One-Time Payments

Guide to set up one-time payments in your SaaS starter boilerplate using Stripe.

One-Time Payments

This guide explains how to configure one-time payments in your SaaS using Stripe. One-time payments are ideal for products or services that require a single payment, rather than recurring subscriptions.

1

Create Product and Pricing in Stripe

  1. Log in to your Stripe Dashboard.
  2. Navigate to Products and click Add Product.
  3. Fill in your product details (name, description, images).
  4. Create a Price for the product:
    • Set Pricing model to One-time.
    • Enter the price in your preferred currency.
    • Click Save to generate a price ID.
2

Copy Price ID to .env.local

After creating the product and price, Stripe will generate a Price ID (e.g., price_1MjK2x2eZvKYlo2C3G7abcde).

Add this price ID to your .env.local file:

NEXT_PUBLIC_STRIPE_ONETIME_PRICE_ID=price_1MjK2x2eZvKYlo2C3G7abcde

This allows the to reference the price when creating Stripe Checkout sessions.

3

Remove Unneeded Subscription Price IDs (Optional)

If your project does not require subscriptions, you can safely remove any subscription price IDs from .env.local and configuration files. This keeps your project clean and avoids accidental subscription creation.

4

Include OnetimePricingSection in Landing Page

To display the one-time payment option on your landing page, import and include the OnetimePricingSection component in:

app/(public)/(landing)/page.tsx

Example usage:

import { OnetimePricingSection } from "@/components/landing/OnetimePricingSection"

export default function LandingPage() {
  return (
    <>
      {/* Other landing sections */}
      <OnetimePricingSection />
    </>
  )
}

This component automatically pulls the price ID from your environment variables and renders the checkout button for users.

Tips

  • Always test one-time payments in Stripe test mode before going live.
  • Ensure the .env.local price ID matches the product in your Stripe dashboard.
  • Customize the OnetimePricingSection UI as needed to match your branding.
StripeSubscriptions

On this page

Tips

Content

FeedbackEdit page

© 2025 Ship IT.

Rubix Studios logo