Scaffold production-ready Express 5 + TypeScript projects in seconds. Pick a database ORM, add Docker, and start building.
npx pest-js-appStarting a new Express project means wiring up TypeScript, linting, testing, error handling, env config, and more — every single time. PEST.js does all of that in one command.
- Express 5 — native async error handling, no wrappers needed
- TypeScript — strict mode, path resolution, source maps
- Database — Prisma, Drizzle, or TypeORM with PostgreSQL, MySQL, or SQLite
- Docker — multi-stage Dockerfile + compose with DB health checks
- Testing — Jest + Supertest with real HTTP assertions
- Linting — ESLint flat config + Prettier, pre-commit hooks via Husky
- Deploy — Vercel config included out of the box
npx pest-js-appFollow the interactive prompts — or skip them entirely:
npx pest-js-app --yes --name my-api --database prisma --db-provider postgresql --dockerThen:
cd my-api
npm run devYour API is running at http://localhost:3000.
Usage: npx pest-js-app [options]
Options:
--name <name> Project name (kebab-case)
--database <orm> prisma | drizzle | typeorm | none
--db-provider <db> postgresql | mysql | sqlite
--docker Enable Docker support
--no-docker Disable Docker support
-y, --yes Skip all prompts, use defaults
-v, --version Show version
-h, --help Show help
my-api/
├── src/
│ ├── app.ts Express app (routes + middleware)
│ ├── server.ts Server entry point
│ ├── config/env.ts Typed environment variables
│ ├── routes/health.ts Health check endpoint
│ ├── middleware/
│ │ └── error-handler.ts Global error handler
│ ├── db/ Database setup (if selected)
│ └── lib/prisma.ts Prisma client (if selected)
├── tests/app.test.ts Supertest tests
├── Dockerfile Multi-stage build (if Docker)
├── docker-compose.yml App + DB services (if Docker)
├── tsconfig.json
├── eslint.config.mjs
├── jest.config.js
├── .prettierrc
└── vercel.json
| Script | Description |
|---|---|
npm run dev |
Dev server with hot reload |
npm run build |
Compile TypeScript |
npm start |
Run production build |
npm test |
Run tests |
npm run lint |
Lint with ESLint |
npm run format |
Format with Prettier |
npm run db:migrate |
Run migrations (if DB) |
npm run db:studio |
Database GUI (if DB) |
Full docs at pestjs.vercel.app/docs.
Contributions welcome. See CONTRIBUTING.md.
MIT
