Sourcebot – Self-hosted Perplexity for Your Codebase
Self-hosted code search and AI chat tool that indexes GitHub, GitLab, and local repos, letting you ask natural language questions with inline citations and navigate code directly in the browser.
TL;DR
TL;DR: Sourcebot is a self-hosted code intelligence tool that indexes your GitHub, GitLab, and local repos, then lets you ask natural language questions with inline code citations or search across every repo and branch using regex and boolean logic.
Source and Accuracy Notes
This section is MANDATORY. All links verified from actual source, not guessed.
- Project page: sourcebot.dev
- Source repository: github.com/sourcebot-dev/sourcebot
- License: Functional Source License (FSL-1.1-ALv2) per LICENSE.md — confirmed via GitHub API
- Docs: docs.sourcebot.dev (Mintlify)
- Public demo: app.sourcebot.dev
- HN launch thread: news.ycombinator.com/item?id=44734891 (103 points)
- GitHub stars: 3,500+ (verified via GitHub API)
- Last source verified: 2026-06-23
What Is Sourcebot?
Sourcebot describes itself as “a self-hosted tool that helps humans and agents understand your codebase.” It positions itself as a self-hosted alternative to Perplexity AI — but for code. Instead of web search, it indexes your actual repositories and lets you query them conversationally.
The core capabilities from the README:
- Ask Sourcebot — ask complex natural language questions about your codebase and get detailed answers grounded with inline citations
- Code search — search across all repos and branches, supporting regular expressions, repo/language filters, and boolean logic
- Code navigation — goto definition and find references across all indexed repos (IDE-level navigation)
- Built-in file explorer — explore every file across all repos with syntax highlighting, file tree, and code navigation
Sourcebot uses a reasoning model to search your code, follow code nav references, and produce answers rich with inline citations and navigable code snippets.
Setup Workflow
Prerequisites
- Docker and Docker Compose
- GitHub or GitLab personal access token (for private repos)
- Optional: an LLM provider API key (Anthropic, OpenAI, or local)
Step 1: Download docker-compose.yml
curl -o docker-compose.yml https://raw.githubusercontent.com/sourcebot-dev/sourcebot/main/docker-compose.yml
Step 2: Create a configuration file
In the same directory as docker-compose.yml, create a config.json file. The minimal config from the README indexes the Sourcebot repository itself:
echo '{
"$schema": "https://raw.githubusercontent.com/sourcebot-dev/sourcebot/main/schemas/v3/index.json",
// This config creates a single connection to GitHub.com that
// indexes the Sourcebot repository
"connections": {
"starter-connection": {
"type": "github",
"repos": [
"sourcebot-dev/sourcebot"
]
}
}
}' > config.json
For a real deployment, you would add your GitHub/GitLab credentials and specify the repos you want to index. The full configuration schema covers language model providers, authentication providers, and more.
Step 3: Run Sourcebot
docker compose up
Visit http://localhost:3000 to start using Sourcebot.
Step 4: Configure (index your own repos, connect LLMs)
The configuration file controls what repos to index, which LLM to use, and auth settings. Full documentation is at docs.sourcebot.dev/docs/configuration/config-file.
Key Features In Detail
Ask Sourcebot (Natural Language Code Q&A)
Ask Sourcebot uses the tool’s existing code search and navigation capabilities to let reasoning models search your code, follow references, and provide answers with inline citations. The demo at app.sourcebot.dev shows this in action — you type a question in natural language and get back a cited answer with clickable links into your actual source files.
Code Search
The search supports regular expressions, repo and language filters, and boolean logic. Results are blazingly fast because the repos are pre-indexed. You can search across all branches of all repos simultaneously.
Code Navigation
Goto definition and find references work across all indexed repos, not just the currently open file. This is useful for large monorepos where you want to trace a function call across dozens of packages.
Deployment Model
Sourcebot collects anonymous usage data by default. You can disable telemetry by setting SOURCEBOT_TELEMENTRY_DISABLED environment variable to true in the docker-compose file.
Practical Evaluation Checklist
- Docker-based deployment with docker-compose (verified from README)
- Configuration via JSON schema with comments support
- Supports GitHub, GitLab, and local filesystem repo connections
- LLM integration (Anthropic, OpenAI) configurable
- Auth providers configurable (SAML, OIDC)
- Telemetry opt-out available
- Public demo available at app.sourcebot.dev
- Documentation at docs.sourcebot.dev (Mintlify)
- Active development — last commit June 2026
- 3,500+ GitHub stars
Security Notes
- Self-hosted — all code and data stays on your infrastructure
- Supports auth providers including SAML and OIDC for enterprise SSO
- Telemetry is opt-out (disabled via
SOURCEBOT_TELEMETRY_DISABLED=true) - Private repos require a personal access token, not OAuth — scope it to only the repos you need to index
FAQ
Q: Does Sourcebot work with private GitHub Enterprise or GitLab Self-Hosted? A: Yes. The configuration supports GitHub and GitLab connections. For self-hosted instances, you configure the base URL and access token in the connections block of config.json.
Q: What LLMs does it support? A: Sourcebot supports Anthropic Claude and OpenAI models via API. You configure the provider in the config.json under the LLM settings. A public demo runs at app.sourcebot.dev.
Q: How does it index code? A: Sourcebot indexes repositories at startup and stores a searchable index in Docker volumes. New commits require a re-index operation.
Q: Is this suitable for a large monorepo? A: Yes — code navigation (goto definition, find references) works across all indexed repos, and the search is designed for multi-repo workspaces. The demo shows monorepo-scale navigation.
Conclusion
Sourcebot fills a specific gap: self-hosted, no-Cloud code intelligence. It is useful if you want Perplexity-style Q&A grounded in your own repositories but cannot or do not want to send code to a third-party service. The Docker Compose deployment is straightforward for a developer or small team, and the FSL license permits self-hosting without a commercial agreement.
If you want to try before self-hosting, the public demo at app.sourcebot.dev indexes the Sourcebot repo itself so you can get a feel for the Q&A and search interfaces.
Source: github.com/sourcebot-dev/sourcebot (FSL-1.1-ALv2 license, 3,500+ stars, last pushed June 2026)
Related Posts
dev-tools
Automotive Skills Suite for AI Engineering
Evaluate Automotive Skills Suite for APQP, ASPICE, HARA, safety-plan, and DIA workflows with setup notes, governance risks, and SME review guidance.
5/28/2026
dev-tools
awesome-agentic-ai-zh Roadmap Guide
Explore awesome-agentic-ai-zh as a Chinese agentic AI learning roadmap, with setup notes, track selection, study workflow, and evaluation guidance.
5/28/2026
dev-tools
Baguette iOS Simulator Automation Guide
Set up Baguette for iOS Simulator automation, web dashboards, device farms, gesture input, streaming, and camera testing with Xcode caveats.
5/28/2026