| name | cursor-indexing-issues |
| description | Troubleshoot Cursor codebase indexing: stuck indexing, empty search, @codebase failures, and
performance issues. Triggers on "cursor indexing", "cursor index", "@codebase not working",
"cursor search broken", "indexing stuck".
|
| allowed-tools | Read, Write, Edit, Bash(cmd:*) |
| version | 1.18.0 |
| license | MIT |
| author | Jeremy Longshore <jeremy@intentsolutions.io> |
| tags | ["saas","cursor","cursor-indexing"] |
| compatibility | Designed for Claude Code, also compatible with Codex and OpenClaw |
Cursor Indexing Issues
Diagnose and fix codebase indexing problems. Covers stuck indexing, empty search results, stale results, and performance optimization for large codebases.
Quick Diagnosis
| Symptom | Likely Cause | Quick Fix |
|---|
| Status bar stuck on "Indexing..." | Large codebase or network issue | Add .cursorignore, resync |
| @Codebase returns nothing | Index not built or file excluded | Wait for index, check ignore files |
| @Codebase finds wrong code | Stale index | Resync index |
| Indexing crashes / restarts | Memory or file watcher limits | Increase limits, reduce scope |
| "Unable to index" error | Network blocked or auth expired | Check proxy/firewall, re-auth |
Fix: Stuck Indexing
Step 1: Reduce Scope
Create or update .cursorignore in project root:
# .cursorignore -- exclude non-essential directories
# Build output
dist/
build/
.next/
out/
target/
# Dependencies (always exclude)
node_modules/
vendor/
.venv/
venv/
# Generated / large files
*.min.js
*.min.css
*.bundle.js
*.map
*.lock
package-lock.json
yarn.lock
pnpm-lock.yaml
# Data files
*.csv
*.sql
*.sqlite
*.parquet
*.json.gz
fixtures/
# Media
*.png
*.jpg
*.gif
*.svg
*.mp4
*.woff2
Step 2: Resync Index
Cmd+Shift+P > Cursor: Resync Index
Step 3: Clear Cache (if resync fails)
rm -rf ~/Library/Application\ Support/Cursor/Cache/
rm -rf ~/Library/Application\ Support/Cursor/CachedData/
rm -rf ~/.config/Cursor/Cache/
rm -rf ~/.config/Cursor/CachedData/
Remove-Item -Recurse "$env:APPDATA\Cursor\Cache"
Remove-Item -Recurse "$env:APPDATA\Cursor\CachedData"
Restart Cursor after clearing cache. Full re-index begins automatically.
Fix: @Codebase Returns No Results