This setup ensures Cursor, Bun, Node, Git, and AI agents run in a real Linux filesystem for speed, stability, and correct tooling.
wsl --install
Restart Windows, open Ubuntu, then:
sudo apt update && sudo apt upgrade -y
Download and install Cursor normally on Windows. Inside Cursor, install the WSL extension.
Open Cursor → Settings (JSON) and set:
{
"terminal.integrated.defaultProfile.windows": "WSL (Ubuntu)",
"terminal.integrated.profiles.windows": {
"WSL (Ubuntu)": {
"path": "C:\\Windows\\System32\\wsl.exe",
"args": ["-d", "Ubuntu", "--cd", "/home/<your-user>/code"]
}
},
"terminal.external.windowsExec": "C:\\Windows\\System32\\wsl.exe"
}
Replace <your-user> with your Linux username.
Do not set terminal.integrated.cwd. WSL handles the working directory.
Restart Cursor.
Inside WSL:
mkdir -p ~/code
From WSL:
cd ~/code/my-project
cursor .
In Cursor terminal:
pwd
uname -a
which node
Expected:
pwd→/home/.../codeuname→ Linuxwhich node→ notC:\Program Files
\\wsl$\Ubuntu\home\<your-user>\code
From WSL:
rsync -av --progress /mnt/c/Users/<WindowsUser>/Code/ ~/code/
This preserves git repos, symlinks, timestamps, and large node_modules correctly.
/mnt/c is slow and breaks file watchers, native modules, and AI indexing.
/home is real Linux and is required for Bun, Node, Cursor AI, and monorepos to work correctly.