Productivity & ResearchOpen source codekhoj-ai/khoj

Khoj: Open Source AI Repository & Self-Hosting Guide

Open-source personal AI assistant and self-hosted workspace indexing Markdown, Org-mode, Notion, and PDFs for hybrid local or cloud RAG chat.

GitHub Stars
38,341 stars
Repository License
AGPL-3.0
Last Push (UTC)
Aug 2, 2026
Check the repo's license. Model weights may have a different license.
git clone https://github.com/khoj-ai/khoj.git
View on GitHubOfficial Website
Installpip install khoj-assistant && khoj

Khoj: Architecture & Practical Workflow

Khoj runs as a self-hosted Docker/Python server with native browser, Obsidian, Emacs, and WhatsApp clients—combining local semantic embeddings, scheduled recurring web research automations, and support for Ollama, OpenAI, Anthropic, and Gemini.

Recommended End-to-End Pipeline

Point Khoj at your Obsidian Markdown vault and reference PDFs via Docker, then schedule automated morning summaries using your preferred local or cloud model.

Runtime Target
Self-Hosted / App (GitHub)
Primary Users
Researchers, Note-takers
Code License
AGPL-3.0
Focus Topics
open-source, github, assistant, search, self-hosted

Quick Setup & Installation Steps

Platform target: Self-Hosted / App (GitHub). Always verify environment variables and dependencies in the upstream repository README.

  1. 1Clone the repository from GitHub: `git clone https://github.com/khoj-ai/khoj.git && cd khoj`.
  2. 2Review the AGPL-3.0 license (Check the repo's license. Model weights may have a different license.) and note any separate terms on external model weights.
  3. 3Install or launch the project directly: `pip install khoj-assistant && khoj` (use an isolated Python virtualenv, Node workspace, or Docker volume so dependencies remain clean).
  4. 4Validate end-to-end behavior with a small sample input (Point Khoj at your Obsidian Markdown vault and reference PDFs via Docker, then schedule automated morning summaries using your preferred local or cloud model.)

Hardware & VRAM Notes

Runs on standard developer workstations without specialized hardware unless loading large local weights.

CPU & Memory

Modern multi-core CPU with 8 GB–16 GB RAM for orchestration, CLI agents, OCR/document parsing, or UI workflows (32 GB+ if co-hosting large local LLMs).

GPU / VRAM

Optional unless running local neural weights; pairs cleanly with local inference servers (Ollama / llama.cpp) or remote endpoints.

Runtime Target

Self-Hosted / App (GitHub)

Strengths & Best For

  • Search across your documents
  • Works with local or hosted models
  • Chat interface
  • Best suited for: Researchers, Note-takers

Limitations & Caveats

  • Setup required
  • Answer quality depends on the model
  • Check the repo's license. Model weights may have a different license.

3 Similar Tools on /tools (Productivity)

Prefer a hosted web app instead of managing local weights or Docker containers? Explore these cloud alternatives.

Browse all tools
Self-Hosted Khoj vs. Hosted Alternatives (Genei & Notion AI & Workspace)
FactorKhoj (Self-Hosted)GeneiNotion AI & Workspace
Execution & PrivacyRuns locally via Self-Hosted / App (GitHub); data stays on your disk or private server.Hosted cloud web interface; zero local dependency setup required.Hosted cloud web interface; zero local dependency setup required.
Cost & QuotaAGPL-3.0 code; bound only by local CPU/GPU hardware.Freemium; subject to vendor free-tier limits or paid plans.Freemium; subject to vendor free-tier limits or paid plans.
Primary FitSearch across your documents; Works with local or hosted modelsResearch workspace built for organizing PDFs into project folders, extracting key keywords, and drafting cited notes.Connected AI workspace for docs, notes, project management, and automated summaries.
Key Trade-offSetup requiredRequires internet access and vendor account/quota limits.Requires internet access and vendor account/quota limits.

Matching Ready-Made Prompts

All Prompts →

Customize variables in Live Prompt Studio for Khoj workflows.

NotebookLM Multi-Source Deep Literature ReviewExtraction · Research, Literature Review, Synthesis, Academic
Open in Studio
Competitor Pricing & Feature Teardown Grid from Multiple SourcesExtraction · Competitive Intelligence, Pricing, Market Research
Open in Studio
Enterprise GDPR & Data Retention Privacy Gap AnalysisExtraction · GDPR, Privacy, Compliance, Security Audit
Open in Studio

More Open Source Productivity & Research Repositories

Frequently Asked Questions

What does Khoj do and how does it work?

Khoj (khoj-ai/khoj) is an open-source productivity & research project with 38,341 stars on GitHub. Open-source personal AI assistant and self-hosted workspace indexing Markdown, Org-mode, Notion, and PDFs for hybrid local or cloud RAG chat. Khoj runs as a self-hosted Docker/Python server with native browser, Obsidian, Emacs, and WhatsApp clients—combining local semantic embeddings, scheduled recurring web research automations, and support for Ollama, OpenAI, Anthropic, and Gemini.

Is Khoj free to self-host and use commercially?

Khoj provides open source code licensed under AGPL-3.0. Check the repo's license. Model weights may have a different license. Always verify both source code and model weight licenses in the GitHub repository before commercial deployment.

What hardware, runtime, or VRAM does Khoj require?

Khoj targets Self-Hosted / App (GitHub). Typical installation runs via `pip install khoj-assistant && khoj`. Setup required

How does self-hosting Khoj compare to hosted tools like Genei?

Self-hosting Khoj gives you full local data control, zero per-usage vendor fees, and customizable Self-Hosted / App (GitHub) pipelines—at the cost of managing your own setup and compute. By contrast, Genei (Freemium) runs in the browser with no local installation, though usage quotas and cloud privacy policies apply.

Is Khoj actively maintained and what workflow fits it best?

Repository metadata records 38,341 stars on GitHub with the latest recorded push on Aug 2, 2026. Point Khoj at your Obsidian Markdown vault and reference PDFs via Docker, then schedule automated morning summaries using your preferred local or cloud model.