CLI tool to scaffold FastAPI + Next.js full-stack applications with Fox AI companion
npm install nextpy
> Scaffold full-stack FastAPI + Next.js applications in seconds


NextPy is a powerful CLI tool that helps you quickly scaffold modern full-stack applications with FastAPI backend and Next.js frontend, complete with Docker support and multiple database options.
``bash`
npx -y nextpy my-awesome-app
`bashWith confirmation prompt
npx nextpy my-awesome-app
⨠Features
- š¦ Fox - Your Smart Dev Companion - Intelligent CLI mascot that remembers your preferences and provides contextual suggestions
- FastAPI Backend - Modern, fast Python web framework
- Next.js Frontend - React framework with TypeScript support
- Multiple Database Options - PostgreSQL, MongoDB, or SQLite
- Docker Ready - Complete Docker and Docker Compose setup
- TypeScript - Full TypeScript support for type safety
- Vite - Lightning-fast development with Vite
- Interactive CLI - Beautiful, user-friendly prompts with personality
- Smart Suggestions - Fox learns your preferences and suggests your usual stack
- Best Practices - Production-ready project structure
š¦ What You Get
$3
- RESTful API structure
- Database integration (PostgreSQL/MongoDB/SQLite)
- Environment configuration
- CORS setup
- Health check endpoints
- Docker configuration$3
- TypeScript configuration
- Vite for fast development
- API client setup
- Modern React patterns
- Responsive design ready
- Docker configuration$3
- Docker Compose for local development
- Separate Dockerfiles for frontend and backend
- Environment variable management
- Production-ready configurationsšÆ Usage
$3
`bash
Quick start (recommended)
npx -y nextpy my-projectOr with prompt
npx nextpy my-project
`The CLI will guide you through:
1. Project name
2. Frontend framework (Next.js or Vite + React)
3. Database choice (SQLite, PostgreSQL, or MongoDB)
4. Docker support (yes/no)
5. GitHub repository initialization (yes/no)
6. Automatic setup and installation
$3
`bash
cd my-projectStart with Docker Compose (recommended)
docker-compose upOr start services individually:
Backend
cd backend
pip install -r requirements.txt
uvicorn main:app --reloadFrontend
cd frontend
npm install
npm run dev
`š Access Your Application
- Frontend: http://localhost:3000
- Backend API: http://localhost:8000
- API Docs: http://localhost:8000/docs
š¦ Meet Fox - Your Smart Dev Companion
Fox is NextPy's intelligent CLI mascot that makes project creation delightful and efficient!
$3
- Remembers Your Preferences - "You usually go with Next.js + PostgreSQL. Use that again?"
- Smart Suggestions - Recommends the right database for your project type
- Celebrates Milestones - Special messages for your 1st, 5th, 10th, 25th, and 50th projects!
- Contextual Tips - Provides relevant advice based on your choices
- Personality Modes - Choose how chatty Fox should be
$3
`bash
Verbose - Maximum personality, tips, and commentary
nextpy my-project --fox-mode verboseNormal - Balanced helpfulness (default)
nextpy my-project --fox-mode normalQuiet - Essential messages only
nextpy my-project --fox-mode quietSilent - No Fox messages
nextpy my-project --fox-mode silentSet globally with environment variable
export NEXTPY_FOX_MODE=verbose
nextpy my-project
`$3
`bash
Use your last configuration
nextpy my-new-project --lastCombine options
nextpy my-project --fox-mode verbose --last
`$3
- š§ Smart Memory - Tracks your preferences across projects
- š” Context-Aware - Detects project types (e-commerce, blog, API, etc.)
- šÆ Intelligent Recommendations - Suggests appropriate tech stacks
- š Milestone Celebrations - Acknowledges your progress
- šØ Personality - Witty, dev-focused messages
š Requirements
- Node.js 18+ (for frontend)
- Python 3.11+ (for backend)
- Docker (optional, but recommended)
š ļø Project Structure
`
my-project/
āāā backend/
ā āāā main.py # FastAPI application
ā āāā requirements.txt # Python dependencies
ā āāā .env # Environment variables
ā āāā Dockerfile
āāā frontend/
ā āāā src/
ā ā āāā pages/ # Next.js pages
ā ā āāā components/ # React components
ā ā āāā lib/ # Utilities
ā āāā package.json
ā āāā Dockerfile
āāā docker-compose.yml # Docker orchestration
āāā README.md # Project documentation
``Contributions are welcome! Please feel free to submit a Pull Request.
MIT License - see the LICENSE file for details.
- GitHub Repository
- Report Issues
- npm Package
- Save Time: Skip the boilerplate and start building features immediately
- Best Practices: Pre-configured with industry standards
- Flexible: Choose your database and customize as needed
- Modern Stack: Use the latest and greatest technologies
- Docker Ready: Deploy anywhere with confidence
---
Made with ā¤ļø by VesperAkshay