PostgreSQL
SQLite
MySQL
πŸš€ Drizzle Setup CLI
Zero-Config Database Setup in 30 Seconds
$ npx drizzle-setup
⚑ Instant Setup
πŸ”§ Auto Config
πŸ“¦ Auto Dependencies

πŸ—„οΈ Drizzle Setup CLI

A powerful CLI tool that automatically scaffolds and configures database setup using Drizzle ORM for PostgreSQL, SQLite, MySQL, and more databases.


✨ Features


πŸš€ Quick Start

Navigate to your project directory and run:

npx drizzle-setup

The CLI will guide you through an interactive setup process:

Setup Flow

  1. πŸ—„οΈ Database Selection – Choose from PostgreSQL, SQLite, MySQL, and more
  2. βš™οΈ Configuration Preset – Select from optimized presets for different use cases
  3. πŸ“ Target Directory – Specify where to create your database files
  4. πŸ“‹ Template Selection – Choose from various boilerplate templates
  5. πŸ”§ Config Generation – Automatically create drizzle.config.ts
  6. πŸ” Environment Setup – Update .env with required variables
  7. πŸ“¦ Package Management – Install dependencies via your preferred package manager
  8. βœ… Final Verification – Ensure everything is set up correctly

πŸ—ƒοΈ Supported Databases

PostgreSQL

SQLite

MySQL

Other Databases

Each database type comes with pre-configured templates, optimized settings, and environment variables.


πŸ—οΈ Project Structure

After setup, your project will have a clean, organized structure:

project-root/
β”œβ”€β”€ node_modules/            # Installed dependencies
β”œβ”€β”€ drizzle.config.ts        # Drizzle configuration
β”œβ”€β”€ .env                     # Environment variables
β”œβ”€β”€ .env.example             # Example environment file
β”œβ”€β”€ package.json             # Updated with Drizzle scripts
β”œβ”€β”€ [target-folder]/         # Your database folder
β”‚   β”œβ”€β”€ schema.ts            # Database schema definitions
β”‚   β”œβ”€β”€ index.ts             # Database connection and exports

Perfect for Modern Stacks πŸ—οΈ

This tool shines especially bright with modern frameworks:

πŸš€ Astro Projects

# In your Astro project
npx drizzle-setup
# Choose PostgreSQL + Vercel
# Boom! Database ready for your Astro app

⚑ Next.js Apps

# Perfect for Next.js API routes
npx drizzle-setup
# Select your preferred database
# Start building features, not configs

🎯 Any JavaScript/TypeScript Project

Whether it’s Express, Fastify, SvelteKit, or any other framework - this CLI has got you covered.


Real-World Impact πŸ“ˆ

Before Drizzle Setup CLI:

After Drizzle Setup CLI:


πŸ“„ License

MIT License Β© 2025 Drizzle Team