Installing Linux on Windows 11 sounds pretty straightforward, right? But sometimes, it’s not as smooth as it seems—especially if WSL (Windows Subsystem for Linux) refuses to activate properly, or the distro refuses to install after clicking “Get” in the Microsoft Store. For those who have fought these battles, you’ll know that enabling WSL and getting a Linux distro running can actually be kinda fiddly. The good news is, with a few tweaks and commands, it’s often just a matter of making sure stuff is turned on correctly and that your Windows is up to date. Expect to run a couple of PowerShell commands, check your settings, maybe restart, and suddenly you’re in Linux land—well, almost. Here’s what you need to do, broken down with some hands-on tips and common gotchas.
How to Install Linux on Windows 11
Enable WSL and Virtual Machine Platform properly
If WSL isn’t enabled right, you might end up staring at a blank screen or errors when trying to install your distro. This step is the most crucial because Windows 11 needs to have both Windows Subsystem for Linux and Virtual Machine Platform turned on. Sometimes, checking the box in Turn Windows features on or off isn’t enough, and you’ll need to do it via PowerShell for a cleaner setup—trust me, it makes a difference.
- Open PowerShell as administrator (Win + X then pick Windows PowerShell (Admin) or Terminal (Admin))
- Run these commands:
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
- After running those, it’s a good idea to reboot. Windows has a weird way of needing a restart to really make these features stick.
Once rebooted, double-check in Settings > Privacy & security > For developers that Hyper-V and Virtualization are enabled—as sometimes, virtualization needs a bit of a nudge in BIOS, especially on some laptops. Because of course, Windows has to make it harder than it needs to.
Install your Linux distribution from the Microsoft Store
Head over to the Microsoft Store (just hit the Start menu and type “Microsoft Store”), then search for your preferred distro—Ubuntu is the trusty beginner choice, but Debian, Kali, or openSUSE work too.
If clicking “Get” on Ubuntu hangs or doesn’t install properly, sometimes clearing the cache helps. Close the Store, then run:
wsreset.exe
which resets the Store cache and often fixes weird install problems.
Set up WSL 2 manually if it didn’t default
This is where some setups break. By default, Windows 11 should set your distro to WSL 2, but on some setups, it defaults to WSL 1 or just won’t upgrade automatically. To fix this, open PowerShell (admin again) and run:
wsl --set-default-version 2
This ensures any new Linux distros will use WSL 2, which is way better in terms of performance and features. You can check which versions you have running with:
wsl -l -v
If your installed distro isn’t running WSL 2, set it explicitly:
wsl --set-version Ubuntu-20.04 2
Sometimes, just setting the default version isn’t enough, and you might need to update the Linux kernel drivers manually. You can download the latest WSL2 Linux kernel update package from Microsoft’s site: https://aka.ms/wsl2kernel
Launch your Linux environment and do initial setup
Once installed, open your Linux distro from the Start menu. It’ll run the first-time setup, prompting you for a username and password. That’s standard—just follow the prompts. If things hang here, double-check that your system supports virtualization (look in your BIOS settings for Intel VT-x or AMD-V) and that Hyper-V is enabled—check Turn Windows features on or off again.
On some machines, the first launch may be slow or bug out, but after a reboot or a second try, it’s usually fine. Once in, you can run Linux commands like apt update
and apt install
. Easy enough, once everything’s set.
Start using Linux commands in Windows
Open your distro anytime from the Start menu—no need for a VM or dual boot. Try ssh
, git
, or even run GUI apps if you’ve configured WSLg (Windows Subsystem for Linux GUI).The experience can be surprisingly smooth, once all the pieces are in place. On some setups, it’s worth installing Windows Terminal for a better command line experience—super handy for managing multiple consoles in one window.
Sometimes, WSL needs a little nudge—like running wsl --shutdown
or updating your distro if you encounter strange bugs. But overall, once set up, it feels pretty seamless.
Tips for a smoother setup
- Update Windows: Make sure your Windows 11 is fully updated to avoid compatibility glitches.
- Check virtualization support: It’s crucial—if your BIOS has virtualization disabled, WSL 2 won’t work properly.
- Use latest WSL version: WSL 2 is the way to go, so set it as default and upgrade any distros if needed.
- Keep a backup: Because messing with system features always has some risk—just in case.
- Consult the docs: Microsoft’s official WSL docs are a lifesaver if things go sideways—here’s the link.
Frequently Asked Questions
What exactly is WSL?
It’s just a compatibility layer that lets you run Linux commands directly on Windows—kind of like a mini Linux VM without all the fuss.
Can I run graphical Linux apps?
Yes, especially with WSLg (Windows Subsystem for Linux GUI), which now supports running Linux GUI apps natively on Windows 11. Just make sure you’re on latest versions and configured right.
Is it safe to install Linux this way?
Generally, yes. Just be aware that messing around with system features can cause weird issues—so backups are always a good idea, especially if you’re trying this on a production machine.
Uninstalling Linux distros is easy, right?
Absolutely. Just head to Settings > Apps > Installed Apps, find your Linux distro (like Ubuntu), and click uninstall. Or do it directly from the Microsoft Store.
Summary
- Turn on WSL and Virtual Machine Platform via PowerShell
- Reboot your PC, check BIOS for virtualization support
- Install your Linux distro from the Store, or via command line
- Set WSL 2 as default, upgrade older distros if needed
- Launch and configure your Linux environment
Wrap-up
Getting Linux running on Windows 11 via WSL isn’t always foolproof, but it’s a solid way to have Linux at your fingertips without dual-booting or VMs. Once you get the hang of enabling features and updating the kernel, the actual setup becomes pretty painless. And honestly, it’s wild how closely WSL mimics a native Linux experience now—better than some VM setups. Fingers crossed this helps someone who’s banging their head, because it’s really not that bad once you know the tricks.