Getting Started
Quick setup guide to get Mimir running in minutes
Get Mimir up and running in just a few steps.
Prerequisites
Before you begin, make sure you have:
- Node.js: 20 or later
- PostgreSQL Database: A PostgreSQL database with pgvector extension (Supabase, Neon, self-hosted, etc.)
- LLM Provider: API key for OpenAI, Anthropic, Google, or Mistral
- GitHub (optional): Repository with documentation (MDX) and/or code to ingest
Step 1: Set up PostgreSQL Database
You need a PostgreSQL database with the pgvector extension. You can use any provider:
- Supabase – Create a project, then use Settings → Database for your connection string. With Docker, use the Session Pooler (port 6543) if your database shows "Not IPv4 compatible".
- Neon – Create a project and copy the connection string from the dashboard.
- Self-hosted – Install PostgreSQL and the pgvector extension, then use a connection string like
postgresql://user:password@host:5432/database.
Save your connection string; you'll add it as MIMIR_DATABASE_URL in the next step.
Step 2: Configure mimir-rag
cd mimir-rag
cp .env.example .env
# Edit .env with your PostgreSQL database and LLM credentialsSee the Configuration guide for all available options.
Step 3: Generate API key
Generate a secure API key for your server:
npm run generate-apikeyThis will output an API key that you'll use to authenticate requests to your mimir-rag server.
Step 4: Start the server
make serverThe server will:
- Load your
.envconfiguration - Run Prisma migrations to set up the database schema (if
MIMIR_DATABASE_URLis set) - Start the API on port 3000
Step 5: Trigger ingestion
Ingest your first documentation or codebase:
npm run ingest:cliThis will fetch files from your configured GitHub repositories, extract entities, and store them in your PostgreSQL database.
Next Steps
Once you have mimir-rag running:
- Check out the Configuration guide to learn about all available environment variables
- Learn how to configure multiple repositories
- Set up MCP integration to connect AI assistants
- Explore the API Reference for programmatic access