01Install guides · 15 min
Install WSL on Windows
WSL (Windows Subsystem for Linux) runs a real Linux, usually Ubuntu, inside Windows, so Linux-only tools and guides work on your PC.
Roman Urdu: WSL se Windows ke andar Linux chal jata ha. Agar aap ke tools Linux ke liye bane hein toh yeh install kr lein, warna zaroori nahi.
Cost: Free, from Microsoft.
Windows
- Do you need it? Use WSL if a guide or tool says "Linux or macOS only", or you want the same commands as most tutorials. Skip it if you only use Windows apps, or your PC has 4 GB of RAM or less: every tool on this site also has a native Windows path.
- Check your Windows version: press Win + R, type
winver, press Enter. You need Windows 10 version 2004 or newer (build 19041+) or Windows 11. - Right-click the Start button, open Terminal (Admin) or PowerShell (Admin), and run:
$ wsl --install - Restart the computer when it asks. This installs WSL 2 with Ubuntu.
- After the restart, open Ubuntu from the Start menu. Wait for it to unpack, then pick a Linux username and password. The password does not show while you type; that is normal.
- Update Ubuntu once:
$ sudo apt update && sudo apt upgrade -y - If it hangs at 0.0%, download the distro first:
$ wsl --install --web-download -d Ubuntu - Low RAM? WSL 2 uses up to 50% of your memory by default. Open WSL Settings from the Start menu and lower the memory, or create
C:\Users\<you>\.wslconfigwith the two lines[wsl2]andmemory=2GB. Then restart WSL:$ wsl --shutdown
Check it worked
$ wsl -l -vUbuntu listed with VERSION 2
Common errors
- Error 0x80370102: "The virtual machine could not be started because a required feature is not installed."
- Turn on virtualization in your BIOS/UEFI (often under CPU settings, named Intel VT-x, AMD-V or SVM). Also make sure the Virtual Machine Platform Windows feature is on. See Enable virtualization on Windows.
wsl --installonly prints the help text- WSL is already installed. Run
wsl --list --onlineto see distros, thenwsl --install -d Ubuntu. - WslRegisterDistribution failed with error 0x8007019e
- The WSL feature is not on. Run
wsl --installagain in an admin PowerShell and restart. - "WSL 2 requires an update to its kernel component" (or error 0x1bc)
- Run
wsl --updatein an admin PowerShell, then restart. - Windows feels very slow while Ubuntu is open
- Cap the memory in
.wslconfig(see the last step), close Ubuntu when you are done, or runwsl --shutdown.
Official docs
- Microsoft Learn: Install WSL
- Microsoft Learn: Troubleshooting WSL
- Microsoft Learn: WSL settings (.wslconfig)
Checked against these pages on 2026-12-05. Tools change: if a step differs, the official page wins.