# Fix production issues in Cursor with Sentry MCP and Seer

> Connect the Sentry MCP server to Cursor to query issues, trigger Seer root cause analysis, investigate database performance, and apply fixes in your IDE.

**URL:** https://sentry.io/cookbook/fix-issues-sentry-mcp-cursor/

---

Use the Sentry MCP server in Cursor to pull issues from your projects, trigger Seer root cause analysis, and apply fixes directly in your IDE — no copy-pasting stack traces required.

**Time:** 10-15 minutes | **Difficulty:** Beginner

## What You'll Learn

- Connected the Sentry MCP server to Cursor

- Queried Sentry for top issues across multiple projects using natural language

- Triggered Seer root cause analysis directly from your IDE

- Investigated database performance issues through traces and spans

- Applied Seer-recommended fixes directly in your codebase

**Topics:** Sentry MCP, Seer, Tracing, Error Monitoring, Issues

## Steps

### 1. Add the Sentry MCP server to Cursor

Open Cursor and go to Cursor → Settings → Cursor Settings → MCP. Click to add a new MCP server and enter the Sentry MCP server URL. You can also add it manually by editing your mcp.json file. When you first connect, Cursor will open a browser window prompting you to log in with your Sentry organization and authorize the OAuth connection. Once authenticated, all of the available Sentry MCP tools are ready to use in Cursor chat.

### 2. Ask Cursor for your top issues

Open the Cursor chat window and ask about the issues in your Sentry projects using natural language. The MCP server supports natural language queries, so you do not need exact project slugs or issue IDs. Behind the scenes, the MCP server will look up your organizations, find matching projects, and return the top unresolved issues.

### 3. Trigger Seer root cause analysis on the results

Once Cursor returns the list of issues, ask it to fix them using Seer. The MCP server will trigger a Seer root cause analysis for each issue. Seer examines stack traces, tracing data, logs, profiles, and your connected codebase to determine why each issue is happening. This step takes a few minutes to complete, depending on how many issues you send.

### 4. Review the root cause analysis

As Seer finishes each analysis, Cursor will display the results inline. Expand each issue to see the root cause analysis, including the sequence of events that led to the error and the recommended fix. This is the same information you would see on the Issue Details page in Sentry, but pulled directly into your editor. Cursor will then begin applying the suggested fixes to your codebase based on the analysis.

### 5. Investigate database performance issues

Open a new Cursor chat tab and query for performance problems. The MCP server can search your traces and spans to find slow database queries, connection issues, and other performance bottlenecks. The results include specific query details, latency stats, and the affected endpoints.

### 6. Feed performance findings back to Cursor for a fix

Take the performance details the MCP server returned — slow queries, affected tables, latency numbers — and ask Cursor to debug and fix the underlying code. Cursor can use the span and trace data as context to propose optimizations like query rewrites, indexing changes, or connection pooling adjustments.

### 7. Verify fixes in Sentry

After deploying your changes, confirm the issues are resolved. Check [Issues](https://sentry.io/orgredirect/organizations/:orgslug/issues/) to see if the error has stopped reproducing. For performance fixes, check the [Trace Explorer](https://sentry.io/orgredirect/organizations/:orgslug/explore/traces/) to compare latency before and after your changes.

## FAQ

**Do I need to install anything to use the Sentry MCP server?**

No. Sentry hosts and manages a remote MCP server with OAuth authentication. You just add the URL to your client and log in.

**Does the MCP server work with IDEs other than Cursor?**

Yes. The Sentry MCP server works with Claude Desktop, Claude Code, VS Code with GitHub Copilot, Windsurf, Warp, Codex, and any client that supports OAuth and Streamable HTTP. See the full list in the Sentry MCP documentation.

**What can I ask the MCP server besides fixing issues?**

The MCP server provides over 16 tools. You can query issues, search for errors across files and projects, check releases, look up project DSNs, investigate performance data through traces and spans, and trigger Seer analysis — all through natural language prompts.

**Does Seer need access to my GitHub repos?**

Seer works without GitHub access, but its analysis is significantly better with it. Connecting your repositories through the Sentry GitHub integration lets Seer examine your actual source code alongside Sentry telemetry to find root causes more accurately.

**Is my code data used for AI model training?**

No. Sentry does not use your data, including your application error information and source code, to train generative AI models. AI-generated output from your data is shown only to you.

---

*Source: [sentry.io/cookbook/fix-issues-sentry-mcp-cursor/](https://sentry.io/cookbook/fix-issues-sentry-mcp-cursor/)*
