A production-ready SvelteKit website template for service businesses — plumbing, HVAC, roofing, landscaping, and similar trades. Built as a pnpm monorepo with a Sanity CMS back-end and Vercel deployment.
/studio@theme configuration, no tailwind.config.tssvelte-service-template/
├── apps/
│ └── web/ ← SvelteKit app (adapter-vercel)
│ ├── src/
│ │ ├── lib/
│ │ │ ├── components/ ← UI, section, form, and extension components
│ │ │ ├── config/ ← Feature flags (features.ts)
│ │ │ ├── extensions/ ← CRM, payment, auth extension modules
│ │ │ ├── sanity/ ← Sanity clients and GROQ queries
│ │ │ ├── server/ ← Server-only: email, validation, lead-handler
│ │ │ └── types/ ← Shared TypeScript types
│ │ └── routes/ ← SvelteKit routes
│ └── .env.example ← All supported environment variables
├── packages/
│ └── sanity/ ← Sanity schema package + seed data
│ ├── schemas/ ← Document and object type definitions
│ └── seed/ ← Seed data + import script
└── docs/
└── extensions/ ← Setup guides for each optional extension
git clone <repo-url> my-project
cd my-project
pnpm install
cd packages/sanity
npx sanity init --bare
# Note the project ID
cp apps/web/.env.example apps/web/.env
cp packages/sanity/.env.example packages/sanity/.env
Fill in both .env files. At minimum you need:
SANITY_PROJECT_ID / PUBLIC_SANITY_PROJECT_IDSANITY_API_TOKENRESEND_API_KEY + RESEND_FROM_EMAIL + RESEND_OWNER_EMAILTURNSTILE_SECRET_KEY + PUBLIC_TURNSTILE_SITE_KEY (use test keys for dev)cd packages/sanity
pnpm seed
# From the repo root:
pnpm --filter web dev
# Or from apps/web:
cd apps/web && pnpm dev
Open http://localhost:5173. The Sanity Studio is at http://localhost:5173/studio.
Edit the CSS theme tokens in apps/web/src/app.css:
@theme {
--color-brand-primary: oklch(55% 0.2 250); /* primary brand color */
--font-display: 'Your Font', sans-serif;
/* ... */
}
Update apps/web/.env with SITE_BUSINESS_NAME, SITE_PRIMARY_PHONE, etc. These are used in email templates.
For CMS-driven content, update the siteSettings document in Sanity Studio.
Add your actual services in Sanity Studio under Services. Each service gets its own page at /services/{slug}.
See docs/extensions/README.md for the full list of optional integrations and setup guides.
apps/web.apps/web/.env.The project uses @sveltejs/adapter-vercel and includes a vercel.json at the repo root.
All PUBLIC_ prefixed variables must also be added to Vercel — they are not automatically public.
| Layer | Technology |
|---|---|
| Framework | SvelteKit 2 + Svelte 5 |
| Language | TypeScript (strict) |
| Styling | Tailwind CSS v4 |
| CMS | Sanity v3 |
| Resend | |
| Spam protection | Cloudflare Turnstile |
| Package manager | pnpm workspaces |
| Deployment | Vercel (adapter-vercel) |
MIT