Installation
This guide covers the detailed system requirements and manual setup instructions for developers who want to contribute to AnswerFlow or write code. If you just want to run the app as fast as possible, see the Quick Start guide instead.
System Prerequisites
To build and develop AnswerFlow locally without Docker, your machine must have the following installed:
- Node.js (v20 or higher)
- pnpm (v9 or higher) - We strictly use
pnpmworkspaces.npmoryarnwill fail to resolve the internal@answerflow/*packages. - Git
Infrastructure & Setup Options
AnswerFlow requires a database, cache, and storage to run. Choose how you want to run the environment:
The fastest way to get started. Everything is included: database, cache, storage, and email—all provisioned and ready to use.
What's included:
- PostgreSQL database
- Redis cache
- MinIO S3-compatible storage
- Mailpit email service
- Automatic database migrations
Requirements: Just Docker Desktop installed.
Get Started:
docker compose up -dThat's it! No environment variables to configure, no manual setup needed.
Use this option if you need Next.js Hot Module Replacement (HMR) for active development and want to make code changes.
Set up the Infrastructure
Choose your services:
- Database: PostgreSQL locally, or cloud options like Supabase / Neon
- Cache: Redis locally, or Upstash for cloud
- Storage: Create an S3 bucket (see Storage guide)
- Email: Configure a provider (see Email Delivery guide)
- Queues: Set up queue adapters (see Queue Adapters guide)
- Push Notifications: Configure notifications (see Push Notifications guide)
Configure Environment Variables
AnswerFlow uses separate environment files for different parts of the system. You must copy .env.example to .env and fill in your connection strings in the following locations:
apps/web/.env(Frontend & API)apps/worker/.env(Background Processor)packages/db/.env(Database Migrations)
See the Environment Variables guide for detailed configuration instructions.
Migrate the Database
This applies your Prisma schema to the database:
pnpm --filter @answerflow/db run migrate:deployStart the Development Server
Launch the frontend, worker, and docs site in one command:
pnpm dev