A developer-friendly CRM starter built with Next.js, shadcn/ui, and InsForge.
Features · Demo · Quick launch · Step-by-step setup · Deploy · Customization
An authenticated CRM starter built with Next.js, shadcn/ui, and InsForge. It ships with a visual sales pipeline, lead activity tracking, client conversion flows, project management, and enough structure for developers to adapt it into their own CRM without rebuilding auth, database access, or storage from scratch.
Inspired by the developer experience of Supabase and Vercel starter repositories, this template is designed to be modified, not just demoed.
Build a CRM with InsForge auth, database, storage, and RLS without starting from a blank dashboard.
By default, authenticated users land on a dedicated Developer Guide page. If you want the starter to open directly on the CRM dashboard instead, change DEFAULT_LANDING_ROUTE in lib/constants.ts to /dashboard.
- Lead management with CRUD, scoring, notes, and ownership metadata
- Drag-and-drop pipeline for visualizing stages and moving leads forward
- Lead activities, follow-ups, and document uploads
- Lead-to-client conversion flow
- Client and project management screens
- InsForge authentication with email/password and OAuth providers
- Row Level Security policies that scope CRM records to the authenticated user
- Shared UI primitives built with shadcn/ui patterns
Demo: democrm.insforge.site
The template includes a dedicated in-app developer guide, a CRM dashboard, lead and client management, and a seeded pipeline flow for first-run evaluation.
If you want the fastest path, use the InsForge CLI and follow the prompts:
npx @insforge/cli createFrom there:
- Choose the CRM template
- Follow the prompt flow to create or connect your InsForge project
- Let the CLI handle the initial setup
- Choose to deploy with InsForge automatically from the guided flow
Use the step-by-step setup below if you want to inspect the repo, edit environment variables manually, or control the migration flow yourself.
If you have not already done so, clone the repository and install dependencies:
git clone https://github.com/InsForge/insforge-templates.git
cd insforge-templates/crm
npm installGo to the InsForge dashboard, create a project, and click Connect → CLI to get the link command:
npx @insforge/cli link --project-id <your-project-id>Copy the example file:
cp .env.example .env.localThen populate .env.local with your project values (find these in the InsForge dashboard under Connect → API Keys):
| Variable | Required | Description |
|---|---|---|
NEXT_PUBLIC_INSFORGE_URL |
Yes | Your InsForge project URL |
NEXT_PUBLIC_INSFORGE_ANON_KEY |
Yes | Public/anon key for the linked project |
NEXT_PUBLIC_APP_URL |
Yes for production OAuth | Public app URL used for OAuth callbacks outside local development |
For local development, set NEXT_PUBLIC_APP_URL=http://localhost:3000.
You can either ask your agent using this prompt:
help me create table and seed data from migrations/db_init.sql
Or run the command directly:
npx @insforge/cli db import migrations/db_init.sqlThis creates the CRM tables, RLS policies, storage bucket, and helper RPCs used by the starter.
npm run devOpen http://localhost:3000, sign up your first user, and use the in-app Seed CRM defaults action from the developer guide to create sample lead sources and pipeline stages.
To deploy the starter on Vercel:
- Import the repository into Vercel
- Set
NEXT_PUBLIC_INSFORGE_URL - Set
NEXT_PUBLIC_INSFORGE_ANON_KEY - Set
NEXT_PUBLIC_APP_URLto your deployed app URL - Deploy the project
- Run
npx @insforge/cli db import migrations/db_init.sqlagainst the linked InsForge project if you have not already applied the schema
After deploying, sign in, confirm the dashboard loads successfully, and seed the default CRM data if needed.
- Add the column in
migrations/db_init.sql - Re-run the migration against your InsForge project
- Update the TypeScript payloads in
lib/queries.ts - Expose the field in
components/leads/add-lead-form.tsxandcomponents/leads/lead-detail.tsx
Use the seeded defaults as an example, then insert or rename stages in lead_stages.
insert into public.lead_stages (name, order_index, user_id)
values ('Qualified', 2, auth.uid());The dashboard includes a Seed CRM defaults action that calls /api/seed. You can:
- adjust the
seed_crm_defaultsRPC inmigrations/db_init.sql - keep the RPC and swap the inserted records
- remove the button entirely if you do not want seeded data in your product
