An open API service indexing awesome lists of open source software.

https://github.com/tejashVaishnav/Fast-saas-next.js-boilerplate

SaaS in a box: A lean boilerplate for rapidly launching your product. Built with next.js+prisma+supabase+stripe+next-auth+shadcn+tailwind+nodemailer, Perfect for developers who want to focus on their unique product features rather than reinventing the wheel.
https://github.com/tejashVaishnav/Fast-saas-next.js-boilerplate

fast-saas nextauth nextjs nextjs14 nodemailer prisma rate-limiting reactform redis shadcn-ui starter-kit starter-template starter-template-nextjs stripe stripe-subscriptions supabase tailwindcss typesc upstash zod

Last synced: about 1 month ago
JSON representation

SaaS in a box: A lean boilerplate for rapidly launching your product. Built with next.js+prisma+supabase+stripe+next-auth+shadcn+tailwind+nodemailer, Perfect for developers who want to focus on their unique product features rather than reinventing the wheel.

Awesome Lists containing this project

README

          

# FastSaas: Everything you need to take-off soon as possible.
![alt text](https://raw.githubusercontent.com/tejashVaishnav/Fast-saas/master/public/thumbnail.png)
Ultimate SaaS Kickstarter: A lean boilerplate for rapidly
launching your product. Built with modern technologies, Perfect
for developers who want to focus on their unique product features
rather than reinventing the wheel.

## Table of Contents

1. [Supabase Configuration](#supabase-configuration)
2. [Google Single Sign-On (SSO) Integration](#google-single-sign-on-sso-integration)
3. [Email Configuration with Nodemailer](#email-configuration-with-nodemailer)
4. [Stripe Integration](#stripe-integration)
5. [Upstash Setup (Optional)](#upstash-setup-optional)
6. [Additional Considerations](#additional-considerations)

## Supabase Configuration

1. Access the [Supabase dashboard](https://supabase.com/dashboard/project/)
2. Retrieve the following connection strings:
- `POSTGRES_PRISMA_URL`
- `POSTGRES_URL_NON_POOLING`
3. Add these URLs to your project's `.env` file
4. Install the Supabase client library in your project

## Google Single Sign-On (SSO) Integration

1. Set up a Google Cloud Platform project
2. Configure OAuth 2.0 credentials
3. Obtain the Client ID and Client Secret
4. Implement Google SSO in your application (e.g., using NextAuth.js)
5. Add the following environment variables:
- `GOOGLE_CLIENT_ID`
- `GOOGLE_CLIENT_SECRET`

## Email Configuration with Nodemailer

1. Enable 2-Step Verification for your Google account
2. Generate an App Password specifically for your application
3. Configure Nodemailer to use this App Password for sending emails
4. Add the following to your `.env` file:
- `GOOGLE_APP_PASSWORD`

## Stripe Integration

1. Sign up for a [Stripe account](https://dashboard.stripe.com/register)
2. Retrieve your Stripe secret key from the dashboard
3. Create two subscription products in the Stripe Product Catalog:
- Free tier
- Paid tier (configure as needed)
4. Obtain the price IDs for both subscription tiers
5. Set up a webhook in your Stripe dashboard with the following events:
- `checkout.session.completed`
- `invoice.payment.succeeded`
6. Implement Stripe integration in your application using the Stripe SDK
7. Add the following to your `.env` file:
- `STRIPE_SECRET_KEY`
- `STRIPE_WEBHOOK_SECRET`

## Upstash Setup (Optional)

For rate limiting:

1. Sign up for an [Upstash account](https://upstash.com/)
2. Create a new Redis database
3. Obtain the connection details (endpoint and token)
4. Implement rate limiting in your application using Upstash Redis
5. Add the following to your `.env` file:
- `UPSTASH_REDIS_URL`
- `UPSTASH_REDIS_TOKEN`

## Additional Considerations

- Ensure all sensitive information (API keys, secrets) is stored securely in environment variables
- Implement proper error handling and logging throughout your application
- Consider setting up monitoring and analytics to track usage and performance
- Regularly update dependencies and security patches
- Implement proper authentication and authorization mechanisms
- Set up a CI/CD pipeline for streamlined deployment

## Contributing

We welcome contributions to this open-source boilerplate. Please read our [CONTRIBUTING.md](CONTRIBUTING.md) file for details on how to submit pull requests.

## License

This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details.
This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app).

## Getting Started

First, run the development server:

```bash
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
```

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.

This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font.

## Learn More

To learn more about Next.js, take a look at the following resources:

- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.

You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome!

## Deploy on Vercel

The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.

Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details.