LogoShipSaaS
User Guide

FAQ

Frequently asked questions, troubleshooting, and best practices for using the ShipSaaS SaaS template

Here is a summary of the most common questions developers face when installing, configuring, and using ShipSaaS.


Core Concepts & Tech Stack

What is ShipSaaS?

ShipSaaS is an extremely fast, lightweight, and highly modular SaaS template built on the NextJS framework (ShipStack) and optimized specifically for the Cloudflare Workers / Pages edge network. It integrates all core features required by modern SaaS applications (authentication, database, subscription payments, email services, AI inference, etc.), helping you launch your paid applications within an hour.

Why choose NextJS and Cloudflare Workers?

  • NextJS (ShipStack) provides enterprise-grade Inversion of Control (IoC) and Dependency Injection (DI) mechanisms, making the architecture highly modular and loosely-coupled. It offers superb type safety and scalability, making it much more capable when handling complex business logic compared to a T-based architecture (like TanStack Start).
  • Cloudflare Workers feature zero cold starts, global edge distribution, serverless hosting, and an extremely generous free tier. Combined with D1 (SQLite) and R2 (Object Storage), you can start your project at zero cost.

Database & Storage Questions

How do I connect to the Cloudflare D1 database locally?

When running locally, Wrangler automatically creates a local SQLite file to emulate the D1 database. You don't need complex configurations. Just run the migration command when initializing the project to apply it to the local emulator:

bun run db:bootstrap:local

Where is the locally emulated database data stored?

Locally emulated D1 database and R2 storage data are typically stored in the .wrangler folder under the project root directory. If you want to wipe local test data and start fresh, simply delete this folder and re-run the local migration.


Authentication

What authentication system does ShipSaaS use?

We have integrated Better Auth as our authentication solution. It is a modern, fast, type-safe, and framework-agnostic web authentication library that supports traditional email/password logins as well as OAuth social logins (GitHub, Google, Microsoft, etc.) for major platforms.


Subscriptions & Payments

What payment systems does the template support?

We currently natively support two major payment platforms:

  1. Stripe: The world's most popular online credit/debit card payment solution, suitable for most businesses and individual developers.
  2. Creem: A modern payment system highly optimized for indie hackers and digital asset sales.

You can configure one or both depending on your needs. Please refer to Payment Configuration for detailed steps.


Deployment & Operations

Why does it say environment variables cannot be found after deploying to Cloudflare?

Cloudflare Workers environment variables need to be bound in the wrangler.jsonc file or added in the Worker settings on the Cloudflare Dashboard.

  • In the development environment, variables are loaded from .dev.env.
  • In the production environment, Wrangler automatically reads configurations in wrangler.jsonc. Please ensure sensitive keys are correctly synchronized before deploying.

On this page