Chat Searcher
Never lose an AI conversation again. Chat Searcher indexes every chat across all your workspaces and lets you find any past conversation in seconds. Found something useful? Import it directly into your current workspace.
Works with Cursor, Windsurf, and other VS Code-based IDEs.
Why?
AI coding assistants don't have a built-in way to search your chat history. Once a conversation scrolls away, it's gone. Chat Searcher fixes that -- it reads your IDE's local storage, indexes everything, and gives you instant full-text search across all your projects. When you find a conversation you need, you can import it into your current workspace so it appears in your chat history.
Features
- Instant full-text search -- find any conversation by keyword using the BM25 ranking algorithm
- Lightning-fast indexing -- indexes hundreds of conversations in ~4 seconds using a single optimized SQLite query
- Cross-workspace -- searches across all your projects at once, with filtering by workspace
- Full conversation view -- click any result to see the complete chat with all messages
- Import to Workspace -- bring any conversation from another workspace into your current project's chat history
- Correct roles -- properly distinguishes user messages from assistant responses
- Sort by relevance or date -- find the most relevant or most recent conversations
- 100% local -- all data stays on your machine. Nothing is sent anywhere.
- Low memory footprint -- uses the native
sqlite3 CLI to query large databases without loading them into memory
Quick Start
- Install the extension
- Press
Cmd+Shift+H (macOS) or Ctrl+Shift+H (Windows/Linux)
- Type your search query
- Click a result to view the full conversation
- Click Import to Workspace to add it to your current project
That's it. The index is built automatically the first time you open the search panel.
Importing a Chat
When you click Import to Workspace, the import is scheduled as a background task. Quit Cursor (Cmd+Q) and reopen it -- the imported conversation will appear in your chat history. A macOS notification will confirm when the import is complete.
Commands
| Command |
Shortcut |
Description |
| Chat Searcher: Search Chats |
Cmd+Shift+H / Ctrl+Shift+H |
Open the search panel |
| Chat Searcher: Reindex All Chats |
-- |
Rebuild the index (run after new conversations) |
How It Works
- Reads composer metadata from each workspace's local
state.vscdb (small SQLite files, ~100KB each)
- Fetches all conversation bubbles from the global
state.vscdb in a single query using json_extract -- extracting only the fields needed (role, text, timestamp), not the full multi-KB JSON blobs
- Groups bubbles by conversation and builds a BM25 search index in memory
- Search queries return results ranked by relevance with highlighted snippets
The global storage database can be 2+ GB, but Chat Searcher never loads it into memory. It uses the system sqlite3 CLI for zero-copy querying, with a fallback to sql.js for systems where the CLI isn't available.
Import to Workspace
Importing works by copying the composer metadata entry from the source workspace's state.vscdb into the current workspace's database. Since conversation messages are stored globally (not per-workspace), only the lightweight metadata needs to be transferred. The import runs as a background process after Cursor exits to avoid conflicts with Cursor's own database writes.
Supported IDEs
- Cursor
- Windsurf
- Any VS Code-based IDE that stores AI chat in
workspaceStorage/globalStorage
Requirements
- macOS, Linux, or Windows
sqlite3 CLI (pre-installed on macOS and most Linux distros; optional on Windows -- falls back to in-memory loading)
- Python 3 (pre-installed on macOS; required for the Import to Workspace feature)
Privacy
Chat Searcher is fully offline. It reads only local SQLite files on your machine. No network requests, no telemetry, no data collection.
License
MIT -- Alexander Goldberg