An AI-native browser that searches across engines, understands what you're researching, and answers with context.
SuperBrowser pairs a multi-engine search aggregator with a context-aware AI that remembers what you've searched and read β per tab β to deliver smarter, grounded answers. It ships as both a web app and a cross-platform desktop app.
| π Live Web App | superbrowser-d6441.web.app |
| πΎ Desktop App | Download .exe / .dmg / .AppImage from the live website |
| π¦ Repository | github.com/PandyaJeet/SuperBrowser |
| π€ Contributing | CONTRIBUTING.md Β· Code of Conduct |
- Why SuperBrowser?
- Features
- How It Works
- Architecture
- Tech Stack
- Getting Started
- Configuration
- Running the Desktop App
- API Reference
- Project Structure
- Contributing
- License
Traditional search hands you ten blue links and forgets everything the moment you click away. SuperBrowser does three things differently:
- π One query, many engines. It searches Google, Bing, and DuckDuckGo at once β with automatic scraper fallbacks if an API call fails β so you get broader, deduplicated results from a single box.
- π§ It remembers your research. Every query you run and every page you open is captured into a per-tab context. Open a new tab and you get a clean slate; stay in one and your trail compounds.
- π€ The AI uses that context. When you switch to AI mode and ask a follow-up, the assistant already knows what you've been looking at β so answers are grounded in your session, not generic.
The result is a research loop: Search β Context captured β Ask AI β Smarter answer.
- Aggregated results from Google, Bing, and DuckDuckGo behind one search box.
- Resilient fallback: if SerpAPI returns nothing or errors, SuperBrowser transparently switches to direct web scrapers (BeautifulSoup) for the same engine.
- Deduplication & ranking across sources, plus Google Shopping results for product queries.
- Response caching with
X-Cache: HIT/MISSheaders to keep repeat searches fast.
- Five answer styles:
default,chatgpt,gemini,perplexity, andclaude, each driven by its own system prompt. - Smart live-data routing: a lightweight classifier decides whether your question needs fresh web data (prices, comparisons, news) or can be answered from the model's general knowledge β and only scrapes when it helps.
- Grounded in your session: the assistant references your recent searches and visited pages for relevant, personalized answers.
- Powered by Groq for low-latency inference across Llama 3.1/3.3, Mixtral, and Gemma models.
- Pulls real discussion from Stack Overflow, Reddit, Hacker News, and Dev.to.
- AI-summarized into consensus, tips, debates, and warnings β so you skip the doom-scroll.
- Automatically tracks your queries, results, and visited-page content (first ~5,000 chars).
- Isolated per tab β each tab is its own research thread.
- Visual context badge shows what's being tracked (
π§ Context: X searches, Y results). - One-click JSON export of an entire session for archival or sharing.
- Tab-based browsing with independent state per tab.
- Dark / Light themes, persisted across sessions.
- Smooth motion via Framer Motion, 3D accents via Three.js, and Markdown export of results.
- Runs in the browser or as a native Electron desktop app (Windows / macOS / Linux).
ββββββββββββββββ 1. Search "react hooks" ββββββββββββββββββββββββ
β You type β ββββββββββββββββββββββββββββββΊ β Multi-engine search β
β a query β β (SerpAPI β scrapers)β
ββββββββββββββββ ββββββββββββββββββββββββββββββ ββββββββββββββββββββββββ
β results returned + cached
β
βΌ 2. Query + results auto-saved to this tab's context
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β π§ Per-Tab Context: queries Β· results Β· visited pages β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βΌ 3. Switch to AI mode, pick a persona, ask a follow-up
ββββββββββββββββ classify β (scrape if needed) β synthesize ββββββββββ
β SuperAI β ββββββββββββββββββββββββββββββββββββββββββββββ β Groq β
β (context- β β LLMs β
β aware) β βββΊ "Based on your searches about react hooksβ¦" ββββββββββ
ββββββββββββββββ
SuperBrowser is a decoupled two-tier app: a React/Vite frontend talks to a FastAPI backend over REST. In desktop mode, Electron bundles and supervises the Python backend locally.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β FRONTEND β React 19 + Vite (web) Β· Electron 39 (desktop) β
β βββββββββββββ ββββββββββββββ βββββββββββββββββββββββββββββββββββ β
β β Tab Mgr β β Search Bar β β useContextManager (per-tab hook)β β
β βββββββββββββ ββββββββββββββ βββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββββ
β REST (http://localhost:8000/api/β¦)
βΌ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β BACKEND β FastAPI (Uvicorn, async) β
β ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ βββββββββββββββ β
β β /search/seo β β /search/ai β β /search/ β β /context/* β β
β β β β /contextual β β community β β (per tab) β β
β ββββββββββββββββ ββββββββββββββββ ββββββββββββββββ βββββββββββββββ β
β query classifier Β· persona engine Β· summarizers Β· caching layer β
βββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββ¬ββββββββββββββββββ
β β
βΌ βΌ
βββββββββββββββββ ββββββββββββββββββββββ
β SerpAPI β ββ fallback βββΊ β Web Scrapers β
β Groq LLM API β β (BeautifulSoup) β
βββββββββββββββββ ββββββββββββββββββββββ
Note: Browsing context is scoped per
session_idβtab_id, cached in memory, and persisted as JSON underCONTEXT_STORE_DIR. Context-chat messages use SQLite. Both locations can be redirected to durable storage.
| Layer | Technologies |
|---|---|
| Frontend | React 19, Vite, TailwindCSS, Framer Motion, Three.js / React Three Fiber, Recharts |
| Desktop | Electron 39, electron-builder (NSIS Β· DMG Β· AppImage) |
| Backend | Python 3.10+, FastAPI, Uvicorn, httpx, BeautifulSoup4, cachetools |
| AI & Search | Groq (Llama 3.1/3.3, Mixtral, Gemma), SerpAPI, custom scrapers |
| Hosting / CI | Firebase Hosting, GitHub Actions |
- Node.js 20.19+ or 22.12+ and npm
- Python 3.10+ and pip
- API keys for SerpAPI and Groq (see Configuration)
git clone https://github.com/PandyaJeet/SuperBrowser.git
cd SuperBrowsercd backend
pip install -r requirements.txt
cp .env.example .envNow generate a session token β the backend will not serve any search or context route without one:
python -c "import secrets; print(secrets.token_urlsafe(32))"Put that value in backend/.env as SUPERBROWSER_SESSION_TOKEN, keep it handy for
the frontend step, then start the server:
uvicorn main:app --reload --host 0.0.0.0 --port 8000The API will be available at http://localhost:8000, with interactive docs at http://localhost:8000/docs.
β οΈ If you skip the token, every/api/search/*and/api/context/*request returns HTTP 500 β "Server authentication not configured". The backend fails closed by design and prints a warning at startup telling you exactly this.
Port already in use?
lsof -ti:8000 | xargs kill -9
In a second terminal:
cd frontend
npm install
cp .env.example .env.localSet VITE_SUPERBROWSER_SESSION_TOKEN in frontend/.env.local to the same token
you put in backend/.env, then:
npm run dev -- --host 0.0.0.0Open http://localhost:5173 in your browser. The frontend auto-detects its API base (local, Codespaces, or Electron), so no extra config is needed for local dev.
If the two tokens do not match, searches fail with a visible "Not authorised" banner. That is the expected signal β not a silent empty result list.
The desktop app needs neither variable: Electron generates its own token on first launch and injects it over IPC.
Create a .env file inside the backend/ directory:
# Required β shared secret guarding /api/search/* and /api/context/*
# Generate with: python -c "import secrets; print(secrets.token_urlsafe(32))"
SUPERBROWSER_SESSION_TOKEN=your_generated_token
# Required β powers SuperSEO search across Google, Bing & DuckDuckGo
SERPAPI_API_KEY=your_serpapi_key
# Required β powers all SuperAI responses & summaries
GROQ_API_KEY=your_groq_key
# Optional β CORS allow-list (comma-separated). Defaults to http://localhost:5173
ALLOWED_ORIGINS=http://localhost:5173
# Optional β where per-tab context JSON is persisted.
# Defaults to /tmp/superbrowser_contexts.
CONTEXT_STORE_DIR=/tmp/superbrowser_contexts| Variable | Required | Purpose | Get a key |
|---|---|---|---|
SUPERBROWSER_SESSION_TOKEN |
β | Auth token for all search & context routes. Backend returns HTTP 500 on every gated route without it | generate locally (below) |
SERPAPI_API_KEY (or SERP_API_KEY) |
β | Live search results for SuperSEO | serpapi.com |
GROQ_API_KEY |
β | LLM inference for SuperAI & summaries | console.groq.com |
ALLOWED_ORIGINS |
β¬ | CORS origins for the backend | β |
CONTEXT_STORE_DIR |
β¬ | Directory for persisted per-tab context. Defaults to /tmp/superbrowser_contexts |
β |
Create frontend/.env.local (template: frontend/.env.example):
| Variable | Required | Purpose |
|---|---|---|
VITE_SUPERBROWSER_SESSION_TOKEN |
β (web build) | Must exactly match the backend's SUPERBROWSER_SESSION_TOKEN. Mismatched or missing β every search returns 401 and the UI shows a "Not authorised" banner |
VITE_API_BASE |
β¬ | Override the auto-detected backend URL |
VITE_API_BASE_ELECTRON |
β¬ | Override the backend URL in desktop mode |
Generating the token β run once and use the same value on both sides:
python -c "import secrets; print(secrets.token_urlsafe(32))"Desktop app: neither token variable is needed. Electron generates its own token on first launch, stores it in
settings.json, passes it to the backend it spawns, and attaches it over IPC β so it never reaches renderer JavaScript.Live desktop search and AI still require provider credentials. In the desktop app, open Settings β Open provider key file, add
SERPAPI_API_KEYandGROQ_API_KEY, save, and restart SuperBrowser. Electron creates this per-userprovider-credentials.txtfile in its user-data directory and passes it to the bundled backend throughSUPERBROWSER_ENV_FILE; credentials are not embedded in the installer. Existing process environment variables take precedence.Note:
VITE_*values are bundled into the client build and are visible to anyone who loads the page. This token gates a self-hosted backend; it is not a per-user credential.
If any SerpAPI engine fails or returns nothing, SuperSEO automatically falls back to the matching web scraper β so search keeps working even without a perfect API response.
SuperBrowser can run as a native Electron app that spawns and supervises the Python backend for you.
cd frontend
# Dev: runs Vite + Electron together with hot reload
npm run dev:electron
# Build distributables
npm run dist:win # Windows β NSIS installer
npm run dist:mac # macOS β .dmg
npm run dist:linux # Linux β .AppImageThe distribution commands first build an isolated, pinned PyInstaller environment under backend/.pyi-build, produce a self-contained backend executable, and then bundle it with Electron. Python is required on the build machine but is not required on an end user's machine.
In desktop mode Electron selects an available loopback port, injects the endpoint through the preload bridge, stores app data under Electron's user-data directory, and terminates the backend process on application exit. A single-instance lock prevents duplicate primary instances.
All routes are served under http://localhost:8000. Full interactive docs (Swagger UI) live at /docs.
| Method | Endpoint | Description |
|---|---|---|
GET |
/api/search/seo?q={query} |
Multi-engine search with scraper fallback. |
GET |
/api/search/ai?q={query}&persona={p}&gl={region} |
AI answer (persona-styled, region-aware). |
POST |
/api/search/ai/contextual |
AI answer using full browsing context (body below). |
GET |
/api/search/community?q={query} |
Summarized insights from SO, Reddit, HN, Dev.to. |
Example β contextual AI request
POST /api/search/ai/contextual
Content-Type: application/json
{
"query": "How do I use these together?",
"persona": "perplexity",
"context": {
"queries": ["react hooks", "useEffect"],
"results": [ { "title": "...", "url": "...", "snippet": "..." } ],
"visited_pages": [ { "url": "...", "content": "..." } ]
}
}persona is one of: default Β· chatgpt Β· gemini Β· perplexity Β· claude.
| Method | Endpoint | Description |
|---|---|---|
POST |
/api/context/session/start |
Start a browsing session. |
POST |
/api/context/add_query |
Add a query to a tab's context. |
POST |
/api/context/add_results |
Add search results to a tab's context. |
POST |
/api/context/add_visited_page |
Add visited-page content to context. |
GET |
/api/context/get/{session_id}/{tab_id} |
Fetch a tab's context. |
GET |
/api/context/export/{session_id} |
Export the full session context as JSON. |
POST |
/api/context/chat |
Chat with the AI about your browsing context. |
DELETE |
/api/context/clear/{session_id}/{tab_id} |
Clear one tab's context. |
For deeper detail see CONTEXT_FEATURE.md and TESTING.md.
SuperBrowser/
βββ backend/ # FastAPI app
β βββ main.py # App entry point & router mounting
β βββ routers/ # seo Β· ai Β· community Β· context endpoints
β βββ services/ # groq, super_ai, query_classifier, personas, summarizers
β βββ scrapers/ # Google/Bing/DDG + SO/Reddit/HN/Dev.to scrapers
β βββ utils/ # caching helpers
β βββ requirements.txt
βββ frontend/ # React + Vite + Electron
β βββ src/
β β βββ App.jsx # App shell, tabs, search dispatch
β β βββ components/ # AiInput, CommunityResults, ProductCarousel, β¦
β β βββ config/apiBase.js# API base resolution (web/Codespaces/Electron)
β β βββ useContextManager.js
β βββ electron/ # main.cjs, preload.cjs (desktop runtime)
βββ systemprompt/ # Persona system prompts (perplexity, sonnet, β¦)
βββ .github/workflows/ # CI: star-check, auto-label
Contributions are welcome! Please read CONTRIBUTING.md for setup, issue-claim, branch-naming, and PR conventions, and review our Code of Conduct.
For GSSoC contributions, comment your proposed approach on an issue and wait for assignment before coding.
β Please star this repository before submitting a pull request. Starring is required for your PR to be merged. A
star-checkworkflow reports whether the PR author has starred the repo, and maintainers will not merge unstarred contributions.
Released under the MIT License.
| Profile | Name | GitHub |
|---|---|---|
![]() |
Jeet Pandya | @PandyaJeet |
![]() |
Prince Patel | @Princepatel-027 |
Updates automatically as new contributors merge pull requests. Start contributing and see your profile here?
Built using React, FastAPI, and AI.
β If SuperBrowser helps you, give it a star!





















