
Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag storeAbsolutely! You can definitely turn your project into a reusable template. Here's how to create a template that you (and others) can use for future projects:
The simplest approach is to turn your repository into a GitHub template repository:
Now anyone (including you) can click "Use this template" to create a new project based on your setup. This is great for personal reuse and sharing with others.
To make deployment even easier, you can add a Vercel Deploy Button to your repository's README. This allows one-click deployment to Vercel with environment variable prompts.
Add this to your README.md:
[](https://vercel.com/new/clone?repository-url=https://github.com/YOUR_USERNAME/YOUR_REPO&project-name=my-sanity-project&repository-name=my-sanity-project&env=NEXT_PUBLIC_SANITY_PROJECT_ID,NEXT_PUBLIC_SANITY_DATASET,SANITY_API_TOKEN&envDescription=Required%20Sanity%20environment%20variables&envLink=https://www.sanity.io/docs/api-versioning)Key parameters you can customize in the Deploy Button URL:
repository-url: Your GitHub repository URLproject-name: Default project name in Vercelenv: Comma-separated list of required environment variables (like your Sanity project ID, dataset name, and API tokens)envDescription: Help text shown to users about what these variables are forenvLink: Link to documentation explaining how to get these valuesWhen someone clicks the Deploy Button, Vercel will:
web folder to VercelIf you want to share your template with the broader Sanity community, you can submit it as an official template. According to the Sanity documentation on creating templates, here's the process:
Use the Template Kit: Start with the official Sanity Template Kit or adapt your existing project to match its structure
Validate Your Template: The template kit includes a validation script to ensure it meets Sanity's requirements:
npm run validateSubmit for Review: Once validated, submit your template through the Community Studio
The validator checks for:
README.md with a "Getting Started" section with clear setup instructions.env.example or .env.template files)For your monorepo structure with studio and web folders, make sure to:
.env.example files in both folders showing what environment variables are needed:# studio/.env.example
SANITY_STUDIO_PROJECT_ID=your-project-id
SANITY_STUDIO_DATASET=production
# web/.env.example
NEXT_PUBLIC_SANITY_PROJECT_ID=your-project-id
NEXT_PUBLIC_SANITY_DATASET=production
SANITY_API_READ_TOKEN=your-read-tokenCreate a comprehensive README.md at the root with:
Add a root package.json with helpful scripts:
{
"name": "next-sanity-starter",
"private": true,
"scripts": {
"dev": "concurrently \"npm run dev --prefix studio\" \"npm run dev --prefix web\"",
"install:all": "npm install --prefix studio && npm install --prefix web"
},
"devDependencies": {
"concurrently": "^8.0.0"
}
}For quick personal reuse, you could also create a simple setup script:
#!/bin/bash
# setup.sh - Run this after cloning
echo "Setting up your new Sanity + Next.js project..."
# Install dependencies
cd studio && npm install && cd ..
cd web && npm install && cd ..
# Copy environment templates
cp studio/.env.example studio/.env.local
cp web/.env.example web/.env.local
echo "✅ Setup complete! Next steps:"
echo "1. Add your Sanity project credentials to studio/.env.local and web/.env.local"
echo "2. Run 'npm run dev' to start both studio and web"For your use case, I'd recommend:
.env.example files and setup documentationThe GitHub template + Vercel Deploy Button combination is the most user-friendly approach and exactly what you're looking for. When you want to start a new project, just click "Use this template" on GitHub, then click the Deploy Button to get it live on Vercel in minutes!
Sanity is the developer-first content operating system that gives you complete control. Schema-as-code, GROQ queries, and real-time APIs mean no more workarounds or waiting for deployments. Free to start, scale as you grow.
Content operations
Content backend


The only platform powering content operations
By Industry


Tecovas strengthens their customer connections
Build and Share

Grab your gear: The official Sanity swag store
Read Grab your gear: The official Sanity swag store