I often use Linux, even though Windows is my main operating system. For me, Windows works best for everyday tasks, while Linux is ideal for servers and development environments. Some people agree with this approach; others prefer a single OS for everything.

In practice, I mostly need Linux for working with console tools. For example, I usually run Node.js in a Linux environment. In this post, I’ll show you how to install Debian as a Windows Subsystem for Linux (WSL) on Windows.

Step 1: Open PowerShell as Administrator
First, start PowerShell with administrator privileges.

Step 2: Check if Debian Is Already Installed

Run the following command:

wsl -l -v

If you see output like this, Debian is already installed on your system:

  NAME STATE VERSION

* Debian Running 2
  docker-desktop-data Stopped 2
  docker-desktop Stopped 2

Step 3. Install Debian

If Debian is not listed, install it using this command:

wsl --install -d Debian

You should see something similar to the following output:

Downloading: Debian GNU/Linux
Installing: Debian GNU/Linux
Distribution successfully installed. It can be launched via 'wsl.exe -d Debian'
Launching Debian…
Please create a default UNIX user account. The username does not need to match your Windows username.
For more information visit: https://aka.ms/wslusers

Step 4. Create a Linux User

When prompted, enter a username and password for your Debian environment:

Enter username and password
Enter new UNIX username: mydebianuser
New password:
Retype new password:
passwd: password updated successfully
usermod: no changes

That’s it - Debian is now installed and ready to use in WSL. You can now use Debian for development, scripting, and server-like workloads directly on your Windows machine.