The ultimate Next.js scaffold CLI generator. Customize your stack with Prisma, React Query, Shadcn, HeroUI, and more in seconds.
npx nxt-gen-cli my-project
Skip the repetitive setup and get straight to building.
nxt-gen-cli streamlines Next.js project creation by automating the installation and configuration of commonly used libraries. Instead of manually installing and wiring up Prisma, React Query, Axios, and UI frameworks, this CLI handles it for you through an interactive prompt or command-line flags.
Get started quickly with npm or npx.
Two ways to create your project.
Run without arguments and follow the guided prompts.
nxt-gen-cli
Specify options directly for non-interactive usage.
nxt-gen-cli my-project --prisma --react-query --ui shadcnAvailable flags and arguments.
| Flag | Description |
|---|---|
--prisma | Install Prisma ORM with schema and client |
--react-query | Install React Query (TanStack Query) with provider setup |
--axios | Install Axios HTTP client with configured instance |
--ui <type> | UI library: shadcn, heroui, both, or none |
--framer-motion | Install Framer Motion for animations |
--lucide | Install Lucide React icons |
--examples <type> | Example templates: crud, auth, both, or none |
-V, --version | Output version number |
-h, --help | Display help information |
Generated file structure based on selected options.
my-project/
├── prisma/
│ └── schema.prisma # Prisma schema (if --prisma)
├── src/
│ ├── app/
│ │ ├── api/
│ │ │ └── posts/
│ │ │ └── route.ts # Example API route
│ │ ├── auth/
│ │ │ └── page.tsx # Auth page
│ │ ├── posts/
│ │ │ └── page.tsx # Example page
│ │ ├── layout.tsx # Root layout with Providers
│ │ └── page.tsx # Home page
│ ├── components/
│ │ ├── providers/
│ │ │ └── query-provider.tsx
│ │ └── providers.tsx
│ └── lib/
│ ├── axios.ts # if --axios
│ ├── prisma.ts # if --prisma
│ └── utils.ts
├── package.json
├── tailwind.config.ts
└── tsconfig.jsonIncluded in every project.
Plus: src/ directory structure and @/* import alias
Common project configurations.
Complete setup with database, API, UI, animations, and examples
nxt-gen-cli my-app --prisma --react-query --axios --ui both --framer-motion --lucide --examples bothBackend-focused setup with database and HTTP client
nxt-gen-cli api-service --prisma --axiosBeautiful UI setup with animations and icons
nxt-gen-cli landing-page --ui shadcn --framer-motion --lucideSystem prerequisites.
Node.js
18.17.0 or later
npm
9.0.0 or later
Get help, report issues, or contribute to the project.
Found something not working as expected? Open an issue and help us improve the CLI.
Have an idea for a new feature or improvement? We'd love to hear your suggestions.
For inquiries, collaborations, or direct support, feel free to reach out via email.
Ask questions, share ideas, and connect with other users in GitHub Discussions.
Resources and documentation.
Created by Praboth Charith
MIT License