Overview
Khoj is an open-source personal AI app that the project calls your "AI second brain." You can run it privately on your own computer or use the hosted cloud app. It connects to any local or online language model, so you can pick the model that fits your needs, from Llama 3 and Mistral running on your machine to GPT, Claude, Gemini, or DeepSeek in the cloud.
What sets Khoj apart from a plain chatbot is that it answers from your own material. It reads your documents, including PDFs, Markdown, Word files, Notion pages, org-mode notes, and images, and it can also pull answers from the internet. Semantic search helps you find the right document quickly, and you can build custom agents with their own knowledge, persona, model, and tools.
Khoj is self-hostable and open-source, and it reaches you where you already work: a browser, Obsidian, Emacs, a desktop or phone app, and WhatsApp. It can also automate repetitive research, send personal newsletters and notifications, generate images, and read messages aloud.
What it does
- Chat with any local or online LLM, including Llama 3, Qwen, Gemma, Mistral, GPT, Claude, Gemini, and DeepSeek
- Get answers from your own documents (PDF, Markdown, Word, Notion, org-mode) and from the internet
- Semantic search to find relevant documents quickly
- Build custom agents with their own knowledge, persona, chat model, and tools
- Use it from the browser, Obsidian, Emacs, desktop, phone, or WhatsApp
- Automate research with personal newsletters and smart notifications, plus image generation and text-to-speech
Getting started
You can try Khoj instantly on the hosted cloud app, or self-host it on your own machine. The commands below come from the official setup docs for a local, single-user install.
Try it without installing
Open the hosted app in your browser to use Khoj right away with no setup. This is the fastest way to see what it does before self-hosting.
https://app.khoj.devInstall Khoj locally with pip
Install the package with local model support. On Apple Silicon or an NVIDIA GPU you can prefix the command with the matching CMAKE_ARGS shown in the docs to enable hardware acceleration.
python -m pip install 'khoj[local]'Start the server
Run Khoj in anonymous mode for a local single-user setup. On first run you will be prompted to create an admin account and configure your chat models. The server is ready when the logs show "Khoj is ready to engage."
USE_EMBEDDED_DB="true" khoj --anonymous-modeCommands and code are distilled from the project's own documentation — always check the official repo for the latest.
When to use it
- Build a private knowledge base that answers questions across your PDFs, notes, and Notion docs without sending data to a third party
- Run a self-hosted personal assistant that combines local or cloud LLMs with semantic search over your own files
- Create custom agents with a specific persona, knowledge set, and tools for recurring tasks like research summaries
- Automate repetitive research and receive personal newsletters and smart notifications in your inbox
How Khoj compares
Khoj alongside other open-source assistants & chatbots tools AI/TLDR tracks, ranked by GitHub stars.
| Tool | Stars | What it does |
|---|---|---|
| OpenClaw | ★ 380k | OpenClaw is a self-hosted personal AI assistant that answers you on WhatsApp, Telegram, Slack, Discord, and many other channels, with voice and a live visual canvas. |
| Hermes Agent | ★ 198k | A self-improving personal AI agent from Nous Research that builds skills from experience, remembers across sessions, and reaches you on Telegram, Discord, Slack, and more. |
| Khoj | ★ 35.2k | Self-hostable AI second brain that answers from your docs and the web |
| AgenticSeek | ★ 26.5k | An open-source, 100% local alternative to Manus AI that autonomously browses the web, writes code, and plans tasks while keeping all your data on your machine. |
| Leon | ★ 17.3k | Leon is an open-source personal AI assistant that uses real tools, layered memory, and agent-style planning to complete tasks across local and remote AI providers. |
| Rowboat | ★ 15k | Rowboat connects to your email and meeting notes, builds a long-lived knowledge graph on your machine, and uses that context to draft, summarize, and plan. |
| Eigent | ★ 14.3k | Eigent is an open-source Cowork desktop that builds a custom AI workforce of specialized agents to break down and automate complex tasks on your machine. |
| Microsoft 365 Copilot | — | AI assistant embedded across Word, Excel, Outlook, Teams and other Microsoft 365 apps that drafts, summarizes, and searches over your work data. |