How to Use WSL on Windows 11: A Comprehensive Guide for Beginners

If you’ve ever wanted to use Linux on your Windows PC without dual-booting or virtual machines, Windows Subsystem for Linux (WSL) is your best friend. Windows 11 makes it incredibly easy to install and run Linux right alongside your favorite Windows apps — perfect for developers, students, and tech enthusiasts alike.

In this guide, we’ll explain how to use WSL on Windows 11 — from installation to running your first Linux commands — in simple, step-by-step language that even beginners can follow.


🧠 What Is WSL?

Windows Subsystem for Linux (WSL) is a compatibility layer that allows you to run a full Linux environment directly within Windows — without the need for a virtual machine or separate Linux installation.

You can:

  • Run Linux command-line tools (like bash, grep, and apt)
  • Access Linux files from Windows
  • Run GUI Linux apps (like VS Code or Gedit)
  • Use Linux for development with Docker, Python, Node.js, etc.

💡 Think of WSL as a bridge that connects the power of Linux with the convenience of Windows.


⚙️ Step 1: Check System Requirements

Before you begin, make sure your system supports WSL:

Requirement Details
OS Version Windows 11 (any edition)
Architecture 64-bit
Virtualization Enabled in BIOS/UEFI
Internet Connection Required for installation

To check if virtualization is enabled:

  1. Press Ctrl + Shift + Esc to open Task Manager.
  2. Go to the Performance tab.
  3. Look for “Virtualization” — it should say Enabled.

If it’s disabled, enable it from your BIOS/UEFI settings.


🪜 Step 2: Install WSL on Windows 11

Microsoft has simplified WSL installation into one single command.

🔧 Using Command Prompt or PowerShell

  1. Press Windows + X → select Windows Terminal (Admin).
  2. Run the following command:
    wsl --install
  3. The system will automatically:
    • Enable the required features
    • Download and install the latest Ubuntu distribution by default
    • Set up WSL 2 as the default version
  4. Restart your PC when prompted.

That’s it! You now have Linux installed on your Windows 11 system.


🧩 Step 3: Verify the WSL Installation

After rebooting:

  1. Open Command Prompt or PowerShell.
  2. Type:
    wsl --list --verbose

You should see something like:

NAME      STATE           VERSION
* Ubuntu  Running         2

If you see your distribution listed, WSL is working correctly.


🧮 Step 4: Launch Your Linux Distribution

Once WSL is installed, launch your Linux distro:

  • Open the Start Menu, type your distro’s name (e.g., Ubuntu), and press Enter.
  • Alternatively, type wsl in Command Prompt or Windows Terminal.

You’ll see a Linux command-line interface — your Linux shell — open up.

The first time you launch it, you’ll be asked to:

  • Create a UNIX username
  • Set a password

Now you’re ready to use Linux on Windows!


🧰 Step 5: Update and Upgrade Packages

Just like any Linux installation, you should update your system first.

In your WSL terminal, run:

sudo apt update && sudo apt upgrade -y

This updates all packages and ensures your environment is ready for use.


🧑‍💻 Step 6: Basic Linux Commands You Should Know

Here are some must-know Linux commands for beginners:

Command Description
pwd Show current directory
ls List files and folders
cd Change directory
mkdir foldername Create a new folder
rm filename Delete a file
sudo apt install packagename Install software
cat filename Display file contents

Try running a few of these to get familiar with the Linux environment.


🧱 Step 7: Access Windows Files from Linux

You can access your Windows files directly from WSL under the /mnt directory.

Example:

cd /mnt/c/Users/YourName/Desktop

This path gives you access to your C drive/mnt/c/.

💡 Tip: You can edit Windows files from Linux and vice versa, but avoid editing WSL system files directly from Windows to prevent corruption.


🪟 Step 8: Access Linux Files from Windows

Your Linux files are stored locally too. To access them from Windows:

  1. Open File Explorer.
  2. Type the following in the address bar:
    \\wsl$\
  3. You’ll see your installed Linux distributions. Open one to browse files.

This allows easy file sharing between Linux and Windows.


🧩 Step 9: Installing Additional Linux Distributions

Don’t want to use Ubuntu? You can install other distributions too.

To view available distributions:

wsl --list --online

To install a different one (e.g., Debian):

wsl --install -d Debian

You can switch between multiple distros at any time.


⚡ Step 10: Setting WSL 2 as Default

If you have both WSL 1 and WSL 2, make sure you’re using the latest version (WSL 2).

Check your version:

wsl --list --verbose

Set WSL 2 as default:

wsl --set-default-version 2

WSL 2 offers faster performance, full system call compatibility, and better integration with Docker.


🐳 Step 11: Using Docker with WSL 2

If you’re into development, WSL 2 works seamlessly with Docker Desktop for Windows.

  1. Download Docker Desktop from the official site.
  2. During setup, make sure “Use WSL 2 backend” is checked.
  3. Open Docker Desktop → Settings → Resources > WSL Integration → Enable your distro.

Now you can use Docker commands directly inside WSL!


🧩 Step 12: Run GUI (Graphical) Linux Apps on Windows

Windows 11 supports running GUI Linux applications without needing a display server.

For example:

sudo apt install gedit -y
gedit

The Linux app will open in a window — just like a regular Windows program. You can even pin it to your taskbar.


🧹 Step 13: Managing and Uninstalling WSL

To view installed distributions:

wsl --list --verbose

To unregister (delete) one:

wsl --unregister <DistributionName>

To completely remove WSL:

  1. Open Windows Features.
  2. Uncheck:
    • Windows Subsystem for Linux
    • Virtual Machine Platform
  3. Restart your PC.

🔍 Common WSL Commands Cheat Sheet

Command Function
wsl --install Install WSL
wsl -l -v List installed distributions
wsl -d <name> Run a specific distro
wsl --set-default <name> Set default distro
wsl --shutdown Stop all running distros
wsl --terminate <name> Stop a specific distro

🧩 Troubleshooting Common Issues

1. WSL not recognized

Run Command Prompt as Administrator and execute:

dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart

2. Virtualization is disabled

Enable virtualization in BIOS (under CPU Configuration).

3. Linux apps not opening

Update WSL:

wsl --update

🏁 Conclusion

WSL on Windows 11 gives you the best of both worlds — the power of Linux with the familiarity of Windows. Whether you’re coding, automating tasks, or just learning Linux, WSL makes it easy and fast.

Now that you know how to install, use, and customize WSL, you can explore the Linux ecosystem without leaving your Windows desktop.


❓ FAQs About Using WSL on Windows 11

1. Is WSL free to use?
Yes, WSL is completely free for all Windows 11 users.

2. Can I use multiple Linux distros with WSL?
Absolutely! You can install and switch between multiple distros easily.

3. Is WSL suitable for gaming?
Not really — WSL is primarily designed for development, not gaming.

4. How do I update WSL?
Run wsl --update in Command Prompt as Administrator.

5. Can I run Linux GUI apps?
Yes, Windows 11 fully supports running GUI-based Linux apps using WSL 2.


🧾 Summary: Key Takeaways

  • WSL allows you to run Linux inside Windows 11 effortlessly.
  • Install with a single command: wsl --install.
  • WSL 2 is faster and more compatible — always set it as default.
  • You can run both CLI and GUI Linux apps.
  • Integrates smoothly with Docker, VS Code, and PowerShell.

With WSL, Windows 11 becomes a complete cross-platform development powerhouse — ready for coding, testing, and exploring Linux with zero hassle.

Scroll to Top