How to Install Linux on Windows 10: Step-by-Step Guide for Beginners and Experts

Introduction: How to Install Linux on Windows 10 Safely
If you're searching for how to install Linux on Windows 10, you’ve landed in the right place. Whether you're a developer looking for a robust command-line environment, a student exploring open-source software, or a curious enthusiast wanting more control, Linux offers unparalleled flexibility and power.
This complete guide will walk you through both WSL (Windows Subsystem for Linux) and the dual-boot method, ensuring you can run Linux on your Windows 10 machine seamlessly and securely.
Why You Should Install Linux on Windows 10

Top Reasons to Choose Linux Alongside Windows
- Open-source freedom: Use, modify, and share Linux freely.
- Resource efficiency: Ideal for older or low-spec machines.
- Powerful command-line tools: Excellent for development and system management.
- Security advantages: Linux is less prone to viruses and malware.
- Customization: Fully personalize the OS to your liking.
Whether for programming, cybersecurity, or daily computing, installing Linux on Windows 10 gives you the best of both worlds.
Choose Your Method: WSL vs Dual Boot Linux Installation

Option 1: Use Windows Subsystem for Linux (WSL)
- No need to repartition your hard drive
- Run Linux directly inside Windows
- Share files easily between Windows and Linux
Option 2: Use Dual Boot Method
- Native Linux performance
- Total system resources dedicated to Linux
- Ideal for Linux-first workflows and gaming
What You’ll Need Before You Begin
System Requirements
- Windows 10 (Version 1903 or higher recommended)
- At least 10GB of free storage
- Admin privileges on your account
- Stable internet connection
Optional But Helpful
- USB drive (4GB or more) for dual boot
- External drive for data backup
- A second computer or mobile device to reference this guide during setup
How to Install Linux on Windows 10 Using WSL
Step 1: Enable Windows Subsystem for Linux (WSL)
How to Activate WSL in PowerShell
Open Windows Terminal or PowerShell as Administrator and run:
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
Restart your PC once both commands are executed.
Step 2: Download and Install Your Preferred Linux Distro
Popular Linux Distros Available in Microsoft Store
- Ubuntu (recommended for beginners)
- Debian
- Kali Linux
- openSUSE
- Alpine
Search for your distro in the Microsoft Store, click Install, and wait for the download to complete.
Step 3: Set Up the Linux Environment
- Launch your installed Linux distro from the Start Menu.
- Wait for it to initialize (this may take a few minutes).
- Create a new UNIX username and password when prompted.
How to Use Linux After Installing on Windows 10
Basic Commands to Start With
ls
– list filescd
– change directorysudo apt update
– update packagessudo apt install packagename
– install new software
Pro Tip
Use VS Code with WSL extension for coding in a Linux environment while staying in Windows.
Updating and Maintaining Linux on Windows 10
Keep Your Packages Up-to-Date
Run the following in your terminal:
sudo apt update && sudo apt upgrade -y
Regular updates ensure system stability and security.
How to Install Linux on Windows 10 via Dual Boot
Step-by-Step Dual Boot Setup
This method allows Linux to run natively, offering better performance and hardware access.
Backup Your Data Before Starting
Use external drives or cloud services like OneDrive or Google Drive. It's a crucial step to avoid data loss during partitioning or installation.
Create a Bootable USB Drive for Linux Installation
Tools You’ll Need
- Rufus (https://rufus.ie/)
- BalenaEtcher (https://etcher.io/)
Steps
- Download your desired Linux distro ISO.
- Open Rufus or BalenaEtcher.
- Select the ISO and USB drive.
- Click Start to create the bootable USB.
Prepare Your System: BIOS and UEFI Settings
Change Boot Order and Disable Secure Boot
- Restart and enter BIOS/UEFI (usually by pressing F2, F12, or Del).
- Set USB drive as primary boot.
- Disable Secure Boot under the Security tab.
- Save and exit.
Partition Your Windows Hard Drive
Steps in Disk Management
- Press
Windows + X
, select Disk Management. - Right-click your primary drive (usually C:).
- Select Shrink Volume.
- Allocate at least 20GB of free space for Linux.
Install Linux Next to Windows 10
- Boot into your USB drive.
- Select Install Linux.
- Choose “Install alongside Windows Boot Manager”.
- Assign partitions if required (/, swap, etc.).
- Follow the installation prompts.
- Restart your system after installation.
Understanding the GRUB Bootloader
Upon reboot, you’ll see the GRUB menu, where you can select either:
- Linux OS (default)
- Windows Boot Manager
Switching Between Linux and Windows
Just restart your computer and select the desired OS at boot time using the arrow keys and Enter.
Install Linux GUI Apps on Windows 10 via WSLg
What is WSLg?
WSLg enables running GUI Linux applications within Windows using WSL2.
Example Apps You Can Use
- Gedit (text editor)
- GIMP (image editor)
- Firefox (browser)
- VLC (media player)
No need for X-server or virtual machines—just launch GUI apps like regular desktop software.
Setting Up a Developer Environment After Installing Linux on Windows 10
Must-Have Tools
- IDEs: Visual Studio Code, PyCharm
- Languages: Python, Java, C++, Node.js
- Version Control: Git + GitHub
- Containers: Docker Desktop for WSL
Use package managers like apt
or snap
to install these tools quickly.
Networking and File Sharing Between Windows and Linux
Accessing Windows Files from Linux
Windows drives are mounted at /mnt/c
, /mnt/d
, etc.
Accessing Linux Files from Windows
Use this path:\\wsl$\Ubuntu\home\your-username
You can open these folders via File Explorer too!
How to Uninstall Linux from Windows 10
For WSL
- Open PowerShell as Admin
Run:
wsl --unregister Ubuntu
For Dual Boot
- Delete Linux partitions using Disk Management.
- Use Windows Recovery USB to restore the Windows bootloader.
Best Practices and Security Tips
- Always update your packages regularly.
- Use strong passwords for both OS environments.
- Limit sudo usage unless necessary.
- Avoid unknown PPAs and sources.
FAQs: Installing Linux on Windows 10
Can I install Linux on Windows 10 without losing data?
Yes, using either WSL or proper dual-boot methods ensures your data stays intact if done carefully.
Which method is better: WSL or Dual Boot?
Use WSL for convenience and dual boot for full Linux capabilities.
How do I access Linux from Windows 10?
Launch it from the Start menu if using WSL or choose Linux in GRUB during boot.
Is Linux safe to use on my laptop?
Absolutely. Linux is known for its stability and security.
Can I install Linux apps with a GUI on Windows 10?
Yes, with WSLg, GUI Linux apps run seamlessly on Windows.
Will installing Linux delete my Windows 10 files?
No, if you select the correct partitioning options and don’t overwrite the Windows drive.
Final Thoughts: Should You Install Linux on Windows 10?
If you've ever wondered how to install Linux on Windows 10, now you know it’s easier than ever—with multiple methods catering to every skill level. Whether you're dipping your toes in the Linux waters with WSL or going all-in with a dual-boot setup, Linux on Windows 10 unlocks new possibilities in computing, development, and performance.