基于 Next.js、Tailwind 与 TypeScript 的 SaaS 启动模板,后端使用 Supabase
agentship-lite — Next.js SaaS模板
作者 SortieLabs
AgentShip Lite 是 Sortie Labs 发布的免费 MIT 许可 Next.js + Supabase SaaS 启动模板,包含邮箱魔法链接登录、受保护仪表盘和面向 AI 编码代理的规则与校验脚本。
看看你的网站会是什么样
浏览真实页面截图,比较内容排版与手机效果。点击下方缩略图切换,放大查看整页细节。
全部页面与视图 3
截图用于了解视觉与布局,交互效果请以实际项目为准。
值得关注的模板亮点
从已有项目资料中,快速了解它的特点。
内置 Supabase 邮箱魔法链接认证与会话中间件
提供受 RLS 保护的 profiles 表及数据库迁移脚本
包含 AGENTS.md / CLAUDE.md 代理工作规则与 playbooks 分步手册
scripts/verify.sh 提供类型检查、lint 与构建校验入口
免费 Lite 版采用 MIT 许可,Stripe 计费功能位于付费 Pro 版
模板详细介绍
AgentShip Lite 是一个面向 AI 编码代理扩展的 SaaS 启动模板,技术栈为 Next.js、Tailwind 与 TypeScript,后端使用 Supabase。免费版本提供邮箱魔法链接认证与会话中间件、受 RLS 保护的 profiles 表及迁移脚本、受保护仪表盘,以及一整套“代理就绪”文件:AGENTS.md / CLAUDE.md 工作规则、playbooks 目录下的分步操作手册、scripts/verify.sh 类型检查与构建校验脚本。README 给出的快速开始约 15 分钟,需要自建 Supabase 项目、执行迁移、启用邮箱登录,并手动修改魔法链接邮件模板为 token_hash 形式,否则在跨浏览器或手机端打开链接时可能被弹回登录页。
该模板的定位是让 Claude Code、Cursor 等代理在已有约定和安全规则下工作,而不是从零猜测项目结构。免费版不包含 Stripe 订阅结账、签名校验的 webhook 与套餐门控,这些属于付费的 Pro 版本;Pro 还附带商业许可。代码本身采用 MIT 许可,可免费使用、修改、商用和分发,但演示图片、字体、图标等第三方素材以及 Supabase、托管、支付等外部服务需另行核对许可与费用。
适合你的项目吗?
适用场景
- 用 AI 编码代理从提示词开始搭建 SaaS 项目骨架
- 需要一个带邮箱登录和受保护仪表盘的 Next.js + Supabase 起点
- 希望项目自带代理可读的架构说明、安全规则与校验脚本
- 作为学习 Supabase RLS 与魔法链接认证的示例项目
适合人群
- 习惯用 Claude Code、Cursor 等代理辅助开发的独立开发者
- 需要快速验证 SaaS 想法、暂不需要支付功能的小团队
- 接受自行配置 Supabase 与托管服务的开发者
上手与定制指南
结合仓库当前版本的说明,按下面的资料检查内容、配置与运行要求。
- 1
执行 npm install 并复制 .env.example 为 .env.local
- 2
创建 Supabase 项目,填入 URL 与 anon key,运行 0001_profiles.sql 迁移并启用邮箱魔法链接
- 3
在 Supabase 邮件模板中将魔法链接改为 token_hash 形式,避免跨浏览器打开时登录失败
- 4
npm run dev 后从 /login 登录,进入受保护的 /dashboard
- 5
部署到 Vercel 时需配置相同的环境变量
授权与来源资料
使用条件与限制
免费使用 · 保留许可声明本次收录的是公开仓库中采用 MIT 许可的免费版本;免费范围为该版本代码,不代表外部服务或第三方素材免费。
使用时需要遵守
- 允许免费使用、修改、商用和分发该版本代码。
- 分发代码副本或实质性部分时,保留原作者版权声明和完整 MIT 许可声明。
- 代码按现状提供;担保与责任限制以原许可证及适用法律为准。
额外费用与待核对事项
- 免费 Lite 版不含 Stripe 订阅结账、签名校验 webhook 与套餐门控,这些功能仅在付费的 Pro 版($99)中提供。
- 使用模板需自行注册并配置 Supabase 项目,填入 URL 与 anon key,属于外部服务依赖。
- 需在 Supabase 中手动启用邮箱魔法链接登录方式,否则认证功能不可用。
- 必须手动修改 Supabase 魔法链接邮件模板为 token_hash 形式,否则跨浏览器或手机端打开链接会登录失败。
- 部署到 Vercel 需自行配置相同的环境变量,托管服务可能产生费用。
- Pro 版采用商业许可,允许无限项目但禁止作为启动模板转售;免费 Lite 版为 MIT 许可。
- 项目资料提及可选付费版本或功能;本次仅收录公开免费代码,不包含付费升级。
- 演示图片、字体、图标及其他第三方素材需按各自许可核对,不能仅凭代码的 MIT 许可判断。
- 域名、托管、数据库、支付或 AI 等外部服务可能另外收费。
查看原文依据
Permission is hereby granted, free of charge
许可证原文
Stripe billing and the billing playbooks are in **[AgentShip Pro →](https://sortielabs.gumroad.com/l/yofswq)**.
README 原文
Create a free Supabase project → paste URL + anon key into `.env.local`
README 原文
enable Email (magic link).
README 原文
**Fix the magic-link email template** (don't skip)
README 原文
`vercel` (add the same env vars in Vercel).
README 原文
https://github.com/SortieLabs/agentship-lite/blob/main/LICENSEhttps://github.com/SortieLabs/agentship-lite/blob/main/README.mdThe Pro edition ships under a commercial license (unlimited projects; no resale as a starter).
README 原文
DeepSeek 根据仓库许可证和 README 整理 ·2026-10-03。结果仅覆盖已读取资料,依赖、图片、字体及后续条款变更以各自原文为准。
项目核对记录与介绍依据
模板资料
- 来源平台
- GitHub
- 资料与维护参考分
- 资料较完整 · 88 / 100
- 技术栈
- Next.js · React
- 网站类型
- SaaS · 启动器
这个分数如何计算
本站按许可资料(最高30分)、演示链接(12分)、预览图(10分)、Star数(15分)、记录的维护时间(15分)、描述完整度(8分)、功能记录(5分)和分类资料(5分)计算。它不是代码、安全或性能测试,也不是 Google 评分;有链接不代表已实测可用。
这个项目需要核对什么
- 记录的仓库更新时间
- 2026-07-05
- 截图检查日期
- 2026-10-03
已收录演示链接。请用你的内容与屏幕尺寸检查;有演示不代表表单、认证或支付已经可用。
目录记录的主要技术栈是 Next.js。请通过依赖清单和锁文件核对实际版本与托管要求。这些说明基于收录资料,不代表代码审计或部署实测。
查看具体选型方法 →介绍的制作与核对状态
介绍由 AI 辅助整理目录与仓库资料。仓库作者不等于这篇介绍的审核者。
已完成服务器许可规则与 AI 来源核对;未经过人工编辑审核。
查看当时使用的来源资料
SHA-256: 40ac86dfb52d35788e65e6f7bcf426accce5ee3a95f98b2dfc23acce44c32e8b
2026-10-03T07:21:42.250Z
来源文件 / 仓库# AgentShip Lite
**A free, open-source Next.js 16 + Supabase starter built to be extended by AI coding agents.**
*By [Sortie Labs](https://sortielabs.gumroad.com/l/yofswq) — small studio shipping tools for people who build with AI.*
You're going to build your SaaS by prompting Claude Code, Cursor, or another agent anyway.
Generic starters fight that — undocumented conventions, security rules that live in the
founder's head, no way for the agent to check its own work. AgentShip is structured for it.
This is the **free Lite edition**: auth, database, and the full agent-readiness layer.
Stripe billing and the billing playbooks are in **[AgentShip Pro →](https://sortielabs.gumroad.com/l/yofswq)**.
> ⭐ **If this saves you time, star the repo** — it helps other builders find it.
> New to building with agents? Read the guides: [build an MCP server in TypeScript](https://sortielabs.com/guides/build-mcp-server-typescript) · [a Next.js SaaS an agent can extend](https://sortielabs.com/guides/nextjs-saas-boilerplate-ai-agents).
## What's inside
| | Lite (free) | Pro |
|---|:---:|:---:|
| Next.js 16 + Tailwind v4 + TypeScript | ✅ | ✅ |
| Supabase magic-link auth + session middleware | ✅ | ✅ |
| RLS-locked `profiles` table + migration | ✅ | ✅ |
| Protected dashboard | ✅ | ✅ |
| `AGENTS.md` / `CLAUDE.md` agent rules | ✅ | ✅ |
| `scripts/verify.sh` typecheck+lint+build gate | ✅ | ✅ |
| "Add a protected page" playbook | ✅ | ✅ |
| **Stripe subscription checkout** | — | ✅ |
| **Signature-verified Stripe webhook + plan gating** | — | ✅ |
| **"Add a paid plan" + "webhook event" playbooks** | — | ✅ |
| **Commercial license (unlimited client projects)** | MIT | ✅ |
**[Get AgentShip Pro — $99 →](https://sortielabs.gumroad.com/l/yofswq)**
## Quickstart (~15 min)
1. `npm install && cp .env.example .env.local`
2. Create a free Supabase project → paste URL + anon key into `.env.local` → run
`supabase/migrations/0001_profiles.sql` in the SQL editor → enable Email (magic link).
3. **Fix the magic-link email template** (don't skip): Authentication → Email Templates →
*Magic Link* → change the link to
```
{{ .SiteURL }}/auth/callback?token_hash={{ .TokenHash }}&type=email
```
The default `{{ .ConfirmationURL }}` uses a PKCE code that only works in the same browser
that requested it — users who tap the email on their phone (or whose mail app opens an
in-app browser) get bounced back to the login screen. The `token_hash` link works anywhere.
4. `npm run dev`, sign in at `/login`, land on the protected `/dashboard`. To properly test
the magic link, open it in a *different* browser than the one you requested it from.
5. Ship: `vercel` (add the same env vars in Vercel).
## Why "agent-ready"?
- **`AGENTS.md` / `CLAUDE.md`** — working rules your agent follows: architecture map, security hard rules, async-params gotchas.
- **`playbooks/`** — step-by-step recipes written as agent prompts.
- **`scripts/verify.sh`** — one command the agent rules require after every change, so regressions surface immediately.
- **Security in the structure** — RLS on by default, server-side auth checks, secrets never exposed to the client.
## License
MIT — see [LICENSE](LICENSE). Build anything with it.
The Pro edition ships under a commercial license (unlimited projects; no resale as a starter).
看看同类模板
对比同技术栈与用途的模板,找到更适合的视觉与内容结构。

ai-website-cloner-template
Clone any website with one command using AI coding agents
Next.js · 启动器

Next.js SaaS Starter
Next.js SaaS Starter 是 Next.js 官方维护的 SaaS 起点模板,定位介于学习资源和可直接部署的脚手架之间。
Next.js · SaaS

Next.js Commerce
Next.js Commerce 是 Vercel 团队维护的电商启动模板,基于 Next.js App Router 构建,采用服务端渲染、React Server Components、Server Actions …
Next.js · 电商

Next-js-Boilerplate
Next-js-Boilerplate 是一个面向 Next.js 16、Tailwind CSS 4 和 TypeScript 的启动器,核心定位是开发者体验优先。
Next.js · 启动器

tailwind-nextjs-starter-blog
tailwind-nextjs-starter-blog 是一个面向个人技术博客的 Next.js 与 Tailwind CSS 启动模板,其 v2 版本基于 App Router 与 React Server Comp…
Next.js · 博客

next-forge
Production-grade Turborepo template for Next.js apps.
Next.js · 启动器
