Environment
- OS: WSL2 (Ubuntu) on Windows 11
- Cursor CLI version: 2026.02.27-e7d2ef6
- Same subscription on another machine (Windows PowerShell): Works fine
- Same subscription on another machine (different PC): Works fine
Problem
Cursor CLI works perfectly in Windows PowerShell on the same PC, and also works on a completely different PC.
However, inside WSL on this machine, it fails.
What works:
agent --version
agent login
(already logged in)agent --list-models
(lists all models)agent --model auto
(sometimes works briefly)
What fails:
agent --model gpt-5.4-fast
agent --model gpt-5.2-codex-fast
agent -p "prompt"
agent -c "prompt"(cloud mode)
All failing commands show:
Connection lost, reconnecting...
Retry attempt 1...
Connection lost, reconnecting...
Retry attempt 2...
Connection lost, reconnecting...
Retry attempt 3...
v: [resource_exhausted] Error
WSL Networking Details
- WSL
/etc/resolv.confuses Tailscale DNS:nameserver 10.255.255.254, searchtail987dcf.ts.net nslookup api.cursor.shreturns “Can’t find api.cursor.sh: No answer”- Regular
cursor.comresolves fine - Basic network connectivity to cursor.com works (curl -I succeeds)
What I’ve Tried
- Fresh CLI reinstall (
curlhttps://cursor.com/install` -fsS | bash`) - Reset local state (cleared
.cursor,.cursor-server) - Tried HTTP/1 mode (
useHttp1ForAgent: truein config) - Tested both interactive and non-interactive modes
- Tested cloud mode (
agent -c)
All produce the same resource_exhausted error after reconnect attempts.
Workaround
Using Cursor CLI from Windows PowerShell (not WSL) works perfectly on this same machine.
Expected: Cursor CLI should work in WSL the same way it works in Windows PowerShell
Actual: WSL fails with reconnect/resource_exhausted errors while Windows PowerShell works