Skip to content

Cursor Setup on Latest Ubuntu Version

Prerequisites

  • Ubuntu 24.04 LTS or later
  • Active internet connection
  • Sudo privileges

Installation

  1. Download the latest version of Cursor from the official website:
cd ~/Downloads
wget https://downloader.cursor.sh/linux/appImage/x64 -O cursor.AppImage
  1. Make the file executable:
chmod +x cursor.AppImage
  1. Move the AppImage to an appropriate directory:
sudo mkdir -p /opt/cursor
sudo mv cursor.AppImage /opt/cursor/
  1. Create a desktop shortcut:
cat > ~/.local/share/applications/cursor.desktop << EOF
[Desktop Entry]
Name=Cursor
Exec=/opt/cursor/cursor.AppImage --no-sandbox
Icon=cursor
Type=Application
Categories=Development;IDE;
Comment=AI-powered code editor
EOF

Method 2: Installation via .deb Package

  1. Download the .deb package:
wget https://downloader.cursor.sh/linux/deb/x64 -O cursor.deb
  1. Install the package:
sudo dpkg -i cursor.deb
sudo apt-get install -f

Initial Configuration

First Launch

  1. Launch Cursor from the applications menu or via command:
cursor
  1. Sign in with your Cursor account or create a new one

  2. Accept necessary permissions

Basic Settings

Access settings via Ctrl + , or File > Preferences > Settings

  • Theme: Choose your preferred theme (Dark+, Light+, etc.)
  • Font Size: Adjust to your preference (recommended: 14-16)
  • Auto Save: Enable afterDelay for automatic saving

AI Configuration

  1. Configure your API key (if needed) in settings
  2. Enable real-time code suggestions
  3. Configure preferred AI models (GPT-4, Claude, etc.)

Install useful extensions from the marketplace:

  • GitLens
  • Prettier
  • ESLint
  • Python
  • Docker
  • Live Server

Git Integration

Configure Git if not already done:

git config --global user.name "Your Name"
git config --global user.email "[email protected]"

Ubuntu Optimizations

Disable Apport (to avoid crash reports)

sudo systemctl disable apport.service

Increase File Watchers (for large projects)

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf
sudo sysctl -p

Configure Permissions for Wayland (if applicable)

sudo nano ~/.local/share/applications/cursor.desktop
# Add --enable-features=UseOzonePlatform --ozone-platform=wayland

Essential Keyboard Shortcuts

  • Ctrl + Shift + P: Command palette
  • Ctrl + K: Open AI chat
  • Ctrl + L: Select code and chat with AI
  • Ctrl + /: Comment/uncomment
  • Ctrl + P: Quick file search
  • Ctrl + Shift + F: Global project search
  • Ctrl +`: Open integrated terminal

Troubleshooting

Issue: Cursor won't launch

# Try with no-sandbox mode
/opt/cursor/cursor.AppImage --no-sandbox

Issue: Permission errors

sudo chown -R $USER:$USER ~/.config/cursor

Issue: Theme or graphics rendering incorrect under Wayland

Add these flags at launch:

cursor --disable-gpu-sandbox --enable-features=UseOzonePlatform --ozone-platform=wayland

Updates

Cursor typically updates automatically. To force a manual update, download the latest version from the official website and repeat the installation steps.

Uninstallation

If installed via AppImage:

sudo rm -rf /opt/cursor
rm ~/.local/share/applications/cursor.desktop
rm -rf ~/.config/cursor

If installed via .deb:

sudo apt remove cursor
sudo apt autoremove
rm -rf ~/.config/cursor

Resources

  • Official website: https://cursor.sh
  • Documentation: https://docs.cursor.sh
  • Support: https://forum.cursor.sh