Cursor freezes completely when switching Git branches after committing changes

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Cursor IDE becomes completely unresponsive after switching branches.

After switching branches, the UI freezes entirely and I am unable to:

  • Scroll
  • Click anywhere
  • Close tabs
  • Close Cursor from the taskbar

The only way to exit is by killing the process via Task Manager.

Additionally, the “Changes” panel:

  • Gets stuck on “refreshing”
  • Sometimes shows changes from the previous branch in the newly switched branch, indicating a state inconsistency.

Steps to Reproduce

  • Open a project in Cursor
  • Make some changes in the current branch using agents
  • Save and commit those changes
  • Switch from the current branch to another branch
    Observe the editor behavior immediately after switching

Expected Behavior

  • Cursor should switch branches smoothly
  • UI should remain responsive
  • “Changes” panel should refresh correctly and reflect only the current branch state

Operating System

Windows 10/11

Version Information

Cursor 2.6.20

For AI issues: which model did you use?

Used Cursor agents (default configuration)

Additional Information

  • Issue occurs consistently since 30 March 2026 after switching branches
  • Workflow is completely blocked due to the UI freeze
  • Issue may be related to Git state or caching between branches
  • Observed incorrect carry-over of changes from the previous branch to the new branch

Does this stop you from using Cursor

Yes - Cursor is unusable

Hey, thanks for the detailed report. This sounds really disruptive.

A few things to try while we investigate:

  1. Extensions check: try launching Cursor from the command line with cursor --disable-extensions and reproduce the branch switch. If the freeze doesn’t happen, it might be an extension conflict, especially Git-related ones like GitLens.

  2. Process Explorer: next time it freezes, before killing it via Task Manager, try Ctrl+Shift+P then Developer: Open Process Explorer if you can access it. This would help identify which process is spiking.

  3. Developer Console logs: open Ctrl+Shift+I before switching branches, then check the Console tab after the freeze for any errors.

Also, a couple questions:

  • Roughly how large is the repository, like number of files?
  • How many tabs do you typically have open when the freeze occurs?
  • Do you have any Git-related extensions installed, like GitLens, Git Graph, etc.?

The team is aware of related issues with Git state management during branch switches. Your report helps with prioritization, so let me know what the diagnostics show.

Hi Dean,

Thanks for the suggestions.

I did try running Cursor with extensions disabled earlier, and it seemed fine initially, but the same issue started occurring again after about a week of usage.

Regarding extensions, I do use GitLens. However, I’ve been using the same extension in VS Code with a similar workflow and never faced this issue there. That’s why I’m unsure how GitLens would specifically cause this issue in Cursor.

To answer your questions:

  • Repository size: (you can fill this if needed)

  • Open tabs: (approx if needed)

  • Git extensions: GitLens

Also, one additional observation from today:

When I started Cursor today, it showed/applied changes from a PR I had worked on about 5 days ago, even though I had already moved to a different branch and made new changes after that. This further suggests some kind of stale state or caching issue across branches.

Overall, the issue feels more like something related to Git state handling or caching during branch switches rather than purely an extension conflict.

Let me know if you’d like me to capture logs or run any specific debugging steps again.

Hey, thanks for the extra details.

The fact that --disable-extensions helped for a bit and then the issue came back is interesting. It could mean GitLens isn’t the main cause, but it makes things worse together with how Cursor handles git state when switching branches. The fact that this doesn’t happen in VS Code is a useful detail, noted.

A stale state from a PR from 5 days ago is a pretty serious symptom. This really looks like a git state caching issue across sessions.

A couple requests that would help us move forward:

  1. Repo size. You left this blank. About how many files are in the repo? You can roughly estimate with git ls-files | wc -l in the terminal. Also, how big are the diffs between the branches you’re switching between?

  2. Developer Console logs. Next time, before switching branches, open it, go to the Console tab, and after it freezes, take a screenshot of any errors if you can still scroll in DevTools. This is the most valuable thing for debugging.

As a workaround for now, try switching branches via the terminal using git checkout branch-name instead of the UI, then run Ctrl+Shift+P > Developer: Reload Window. This can avoid a file watcher storm.

The team is aware of this class of issues. Your report helps us prioritize, let me know what you see in the logs.