This guide is part of the MusaBase Arch Linux series. For the complete overview, see the Arch Linux Complete Roadmap.
Dual Booting Arch Linux with Windows is now simpler than ever.
Hi my name is Abdullah Musa and welcome to my blog, MusaBase!. In this comprehensive guide, I'll walk you through dual booting Arch Linux and Windows on your PC. Imagine a computing experience where the sleek, familiar interface of Windows meets the raw, customizable power of Arch Linux, all on one machine. In this guide you'll learn:
- Preparing Storage for Dual Booting with Windows
- Configuring UEFI Settings for Linux Compatibility
- Partitioning and Formatting Drives for Shared Ecosystem
- Arch Linux Base Installation and Bootloader Integration
- Managing Dual Boot Bootloader (GRUB) to Switch Between OS
Although dual booting may seem daunting, like managing two vastly different operating systems, this step-by-step guide will demystify the process. Sure, it's technical, but follow along closely, and i'll turn those "what-ifs" into "how-tos." By the end, you'll reboot with confidence, flipping between Netflix on Windows and a blazing-fast Arch terminal like a tech wizard.
⚡ TL;DR: Dual Boot Arch Linux with Windows, Fast Track
A condensed list of the core commands you need to set up Arch Linux alongside an existing Windows installation on a separate drive (UEFI/GPT). Replace /dev/sdb and partition numbers to match your system.
-
Identify your drives and create partitions:
Choose gpt. Delete any existing partitions on the target drive. Create:lsblk cfdisk /dev/sdb
• 1 GB EFI System partition
• 10 GB Linux swap partition
• Remaining space Linux root partition
Write the table and quit. -
Format the three new partitions:
mkfs.ext4 /dev/sdb4 mkfs.fat -F 32 /dev/sdb2 mkswap /dev/sdb3 -
Mount the filesystems:
mount /dev/sdb4 /mnt mkdir -p /mnt/boot/efi mount /dev/sdb2 /mnt/boot/efi swapon /dev/sdb3 -
Install the base system and generate fstab:
pacstrap /mnt base linux linux-firmware sof-firmware base-devel grub efibootmgr nano networkmanager genfstab -U /mnt >> /mnt/etc/fstab -
Chroot into the new system and configure it:
arch-chroot /mnt ln -sf /usr/share/zoneinfo/Region/City /etc/localtime hwclock --systohc nano /etc/locale.gen # uncomment your locale, e.g. en_US.UTF-8 locale-gen echo "LANG=en_US.UTF-8" > /etc/locale.conf echo "yourhostname" > /etc/hostname passwd useradd -m -G wheel -s /bin/bash yourusername passwd yourusername EDITOR=nano visudo # uncomment %wheel ALL=(ALL:ALL) ALL systemctl enable NetworkManager grub-install /dev/sdb grub-mkconfig -o /boot/grub/grub.cfg exit umount -a reboot -
After reboot install a desktop environment (example KDE Plasma):
sudo pacman -S plasma sddm konsole kate firefox sudo systemctl enable --now sddm -
Enable Windows detection in GRUB:
sudo pacman -Sy os-prober sudo nano /etc/default/grub # remove the # at GRUB_DISABLE_OS_PROBER=false sudo grub-mkconfig -o /boot/grub/grub.cfg -
Reboot and verify the dual boot menu:
Select Arch Linux or Windows Boot Manager from the GRUB screen.reboot
💡 Always back up important data before partitioning. If Windows does not appear after the os-prober step, ensure the Windows EFI partition is accessible and re-run grub-mkconfig. For detailed troubleshooting see the full guide above.
Prerequisites
Before you begin dual booting, ensure you have either a dedicated partition or a separate disk for each operating system. Windows will occupy one partition (or disk) with its own file system, while Linux will use another.
Although you can install Linux on the same drive by creating a separate partition, doing so may compromise Windows' recovery features or even lead to data loss if not done carefully. For this reason, it's crucial to back up your data completely before proceeding. Since Windows is already installed on my PC, I'll move directly to installing Linux and configuring the system for dual boot.
Step 1: Listing All Connected Drives
When we boot into the Arch Linux installer, we are greeted by a familiar screen:
Our first task is to list all connected devices and partitions.
- To do this, type:
lsblk
By clearly understanding the partition layout from the outset, we ensure a smooth dual-boot installation process for both Arch Linux and Windows.
Step 2: Disk Partitioning with cfdisk
For now, if we type cfdisk in the terminal without any arguments, it will by default open the partition table for the first connected physical drive (in our case, sda). Our sda drive contains Windows along with its associated partitions and files.
- To install Linux on a separate disk and create dedicated partitions for it, we need to specify the target disk when launching cfdisk.
- For example, if we want to install Linux on the sdb disk, we run the following command:
cfdisk /dev/sdx - Since I am installing Linux on my second drive, then for me the command is:
cfdisk /dev/sdb
- After pressing Enter, we have this screen:
- Select GPT, because Linux works optimally with GPT (GUID Partition Table).
- After selecting the Label Type, you would have a similar screen:
2.1: Creating the Boot Partition
The boot partition will be responsible for booting our system.
- Select the [ New ] option from the bottom menu and press Enter.
- A prompt appears at the bottom, asking how much space to allocate for this partition.
- Type the desired size using digits.
- Use a capital G for gigabytes (GB) or a capital M for megabytes (MB).
2.2: Creating the Swap Partition
The Swap partition acts as virtual memory when the system runs out of physical RAM.
- Navigate down to select the Free Space.
- Move left to the [ New ] option and press Enter.
- When prompted at the bottom, enter the desired size.
- Allocate between 4 GB and 32 GB based on your system's needs.
2.3: Creating the Root Partition
The root partition will contain the operating system files and other essential directories.
- Navigate down to the Free Space.
- Move left to the [ New ] option and press Enter.
- If you want to allocate all remaining space for this partition, simply accept the suggested size by pressing Enter. If you plan to create additional partitions later, you might allocate around 20 GB or less for the root partition.
2.4: Writing the Partition Table
After creating all the partitions, it's time to commit these changes by writing the new partition table to the disk.
- Navigate right to the [ Write ] option and press Enter.
- A prompt appears at the bottom asking, "Are you sure you want to write the partition table to disk?"
- Type yes and press Enter to commit the changes.
At this stage, all partitions are successfully created and the filesystem is now ready for data storage. If everything went right, then we can see a filesystem like this:
2.5: Finalizing the Partition Setup
- Navigate to the [ Quit ] option and press Enter to return to the Arch Linux terminal.
This step-by-step guide on using cfdisk for disk partitioning ensures that we are aligned in our dual-boot journey for Arch Linux and Windows. By following these detailed instructions, we can confidently partition our drives for a smooth installation experience.
Step 3: Formatting Partitions
Before moving on to the next stage of our Arch Linux installation, we need to format the partitions we created to ensure that our system's storage is properly prepared.
3.1: Listing Storage Devices
3.2: Formatting the Root Partition
Our first task is to format the root partition, which in our setup is /dev/sdb4.
3.3: Formatting the Boot Partition
Next, we format the boot partition. In our configuration, this is /dev/sdb2. We can create a FAT32 filesystem on it.
- To create a FAT32 filesystem for our boot partition, type:
mkfs.fat -F 32 /dev/sdb2
3.4: Setting Up the Swap Partition
The swap partition does not require formatting. Instead, we need to initialize it as a swap area. In our setup, the swap partition is /dev/sdb3.
- To format our swap partition, type:
mkswap /dev/sdb3
With these steps completed, all our partitions are properly formatted and ready for the next phase of our Arch Linux installation. This meticulous process ensures that our dual-boot system is set up securely and efficiently.
Step 4: Mounting Partitions
Now that we have created and formatted our partitions for Arch Linux, it's time to mount them so we can continue with the installation process.
4.1: Mount the Root Partition
First, we mount the root partition (in our case, /dev/sdb4) to the mount point. This partition will house our operating system and other essential files.
4.2: Mount the Boot Partition
Next, we need to mount the boot partition. However, the boot/EFI directory does not exist in the root partition yet. We need to create it first.
Now, mount the boot partition (in our configuration /dev/sdb2) at /boot/efi.
4.3: Enabling the Swap Partition
For the swap partition, we don't have to mount it anywhere; we just have to turn it on. In our setup, it is /dev/sdb3.
4.4: Verifying the Partition Layout
By following these steps, we ensure that our system's partitions are correctly mounted and prepared for the next phase of our dual-boot Arch Linux installation. This methodical approach guarantees a smoother installation process and enhances system reliability.
Step 5: Installing Base Arch Linux System and Afterwards
The rest of the setup for the installation and setting up base Arch Linux system for dual boot with Windows is just the same as installing Arch Linux normally as a single OS for your PC. However, I've covered all the following steps in my How To Install Arch Linux: A Comfy 100% Arch Installation Guide. Follow the given guide from Step 7: Base Arch Linux Installation to Step 12.1: Installing NetworkManager. When completed, come back to this guide and continue on setting up your dual boot PC with Arch Linux and Windows.
Step 6: Install GRUB Bootloader and Reboot
GRUB (GRand Unified Bootloader) is a powerful and flexible bootloader used in Linux systems to manage the startup process. It loads the operating system kernel into memory and allows you to select between multiple OS installations. GRUB supports both UEFI and BIOS, offers a command-line interface, and can be customized for advanced boot configurations.
6.1: Install GRUB
- To install GRUB, run:
grub-install /dev/sdb # OR grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB
Important: Replace /dev/sdb with your hard drive name or label. I installed Linux on my second drive which is /dev/sdb, so I am installing GRUB on this drive.
Now that GRUB is installed, we also need to generate its initial configuration file.
- To generate the GRUB config file, run:
grub-mkconfig -o /boot/grub/grub.cfg
Now that we have completed all the necessary steps, we will exit the chroot environment and unmount all drives to prepare for rebooting into our newly installed Arch Linux system.
6.2: Exit the Chroot Environment
- To exit from the chroot environment, simply run:
exit umount -a reboot
By following these steps, we ensure that our system is properly configured and ready for the next phase. This final reboot will transition us from the installation environment into our fully installed Arch Linux system, paving the way for further customizations and the installation of a graphical interface.
Step 7: Booting into Installed Arch Linux System
After rebooting, our system will load into the GRUB bootloader, where we'll be greeted with this screen:
Once we select *Arch Linux, we will be greeted by Arch Linux's tty1 welcome screen, displaying our configured hostname:
At this point, enter the username and its password we set during the user creation process, then press Enter to log in.
Once we're logged in, our next task is to install a GUI to enhance our experience. We'll install KDE Plasma as our desktop environment with SDDM for graphical logins, and a few essential applications such as Konsole (the KDE terminal emulator), Kate (a powerful text editor), and Firefox for browsing.
- We can install all these components with a single combined command:
sudo pacman -S plasma sddm && sudo pacman -S konsole kate firefox && sudo systemctl enable --now sddm
After the packages and services are installed, we'll be presented with a graphical login screen:
Here, we enter the password for our user account and press Enter. Once authenticated, KDE Plasma will load along with its services, providing us with a fully functional desktop environment.
Now, we have Arch Linux with a modern desktop environment installed on our PC. We can install additional packages and applications through Konsole, our terminal, or directly from KDE's application manager as we tailor our system to our needs.
Step 8: Setting Up Dual Boot
Now, we need to install a utility tool such as (os-prober) and configure our GRUB configuration file so that GRUB can detect other operating systems (like Windows) on our computer.
8.1: Installing OS-Prober
- To install os-prober, first open terminal or konsole.
- Run:
sudo pacman -Sy os-prober
8.2: Configure grub.cfg
Next, we need to configure the GRUB configuration file to enable OS detection. This allows GRUB to include boot entries for operating systems installed on other drives.
- To open the GRUB configuration file, run:
sudo nano /etc/default/grub
- Navigate to the bottom with keyboard's down () arrow key until you find the following line:
#GRUB_DISABLE_OS_PROBER=false
- Remove the # symbol by either pressing the Del key or Backspace key at the beginning of the line.
- Press Ctrl + O to save changes, then press Enter to confirm.
- Press Ctrl + X to exit from nano.
8.3: Updating GRUB
Now that we have installed os-prober and updated our GRUB configuration file, it's time to update GRUB so that it scans for all installed operating systems and generates an updated boot menu.
- To update GRUB's Config file, type:
sudo grub-mkconfig -o /boot/grub/grub.cfg
- If everything is configured correctly, we should see output similar to this:
Found Windows Boot Manager on /dev/sdx@/efi/Microsoft/Boot/bootmgfw.efi
By following these steps, we ensure that our GRUB bootloader is properly configured for dual booting. With os-prober enabled and GRUB updated, our system will automatically include boot entries for both Arch Linux and Windows, making our dual-boot setup seamless and user-friendly.
Step 9. Testing Dual Boot
Now that we have completed all the necessary configurations for dual booting, it's time to verify that everything works as expected.
- Reboot the system.
- Verify the GRUB Menu: When the system boots, the GRUB menu should display entries for both operating systems:
Booting into Arch Linux
Booting into Windows
At this point, we have a fully working dual boot system with Arch Linux and Windows installed on our PC. Whether we continue our everyday work in Windows or dive into the innovative world of Linux for exploration and experimentation, our setup offers the perfect balance to suit our diverse needs.
Frequently Asked Questions: Arch Linux Dual Boot Installation
Can I install Arch Linux on the same physical drive as Windows?
Yes, you can. However, it is safer to use a separate drive if available. If you must use the same drive, you need to shrink your Windows partition from within Windows (using Disk Management) to create unallocated space, then boot the Arch ISO and create your partitions in that free space. The guide assumes a separate drive (/dev/sdb) for clarity, but the partitioning steps are identical – just replace /dev/sdb with the appropriate device name.
Do I need to disable Secure Boot?
For the installation described in this guide, yes. Secure Boot often blocks unsigned bootloaders like the one we use (GRUB). You can disable it in your UEFI firmware settings before booting the Arch ISO. After installation, you can set up Secure Boot with signed bootloaders, but that is an advanced topic.
Why did we create a separate boot partition (1 GB) instead of using the existing Windows EFI partition?
Using a separate boot partition for Arch (mounted at /boot/efi) is cleaner and avoids accidentally breaking Windows’ boot entry. Both partitions are EFI system partitions, and your motherboard will still see both. The guide’s method installs GRUB on the Arch drive (/dev/sdb) and lets your UEFI choose between Windows Boot Manager and GRUB (or you can set GRUB as primary). This separation makes it easier to troubleshoot or remove Arch later without affecting Windows.
How much space should I allocate for root (/) and swap?
It depends on your usage:
- Root (/): 20–30 GB is enough for a base system with a desktop environment and several applications. If you plan to install many games or large software, consider 50 GB or more.
- Swap: Traditionally, swap size was double your RAM, but with modern systems, you can use:
- If you have 8 GB RAM or less → 4–8 GB swap.
- If you have 16+ GB RAM → you may not need swap at all, but having 2–4 GB can help with hibernation.
In the guide we used 1 GB for boot (FAT32), 10 GB for swap, and the rest for root.
Windows is not appearing in the GRUB menu. What went wrong?
This usually happens because os-prober was not run or the GRUB config wasn’t regenerated after enabling it. Follow Step 13 carefully:
- Install os-prober: sudo pacman -S os-prober
- Edit /etc/default/grub and uncomment GRUB_DISABLE_OS_PROBER=false.
- Regenerate GRUB config: sudo grub-mkconfig -o /boot/grub/grub.cfg
If Windows still isn’t found, ensure your Windows drive is mounted (it should be automatically detected by os-prober). Sometimes you need to mount the EFI partition of Windows manually, but os-prober usually handles it.
How do I set Windows as the default boot option in GRUB?
You can change the default entry by editing /etc/default/grub and modifying the GRUB_DEFAULT line. To set Windows as default, you need to know its exact menu entry name. First, list all entries with:
grep menuentry /boot/grub/grub.cfg
Then set, for example:
GRUB_DEFAULT="Windows Boot Manager (on /dev/sda1)"
After editing, save and regenerate the config: sudo grub-mkconfig -o /boot/grub/grub.cfg.
My system boots directly into Windows, ignoring GRUB. How can I fix this?
This means your UEFI boot order still prioritizes Windows Boot Manager. Enter your UEFI/BIOS setup (usually by pressing F2, F12, DEL during startup) and change the boot order to boot from GRUB (often labeled as “Arch Linux”, “GRUB”, or the name of your drive). If you installed GRUB on a separate drive, you might need to select that drive as the first boot option.
How do I fix the clock being off by a few hours when switching between Windows and Arch?
This is a known issue: Windows uses local time for the hardware clock, while Linux uses UTC by default. To make Linux use local time (so it matches Windows), run:
sudo timedatectl set-local-rtc 1
You can verify with timedatectl. Alternatively, you can make Windows use UTC (requires a registry edit), but the above command is simpler.
Can I access my Windows files from Arch Linux?
Yes! Arch Linux can read and write NTFS partitions. You just need to install ntfs-3g:
sudo pacman -S ntfs-3g
Then you can mount your Windows partition (e.g., /dev/sda2) to a folder and access your files. For automatic mounting at boot, add an entry to /etc/fstab.
What should I do if I see “GRUB rescue” after installation?
The “GRUB rescue” prompt means GRUB cannot find its files. This usually happens if you installed GRUB to the wrong disk or if the partition layout changed. To recover, boot from the Arch USB again, mount your root and boot partitions, then reinstall and reconfigure GRUB:
mount /dev/sdXY /mnt # your root partition mount /dev/sdXZ /mnt/boot/efi # your boot partition arch-chroot /mnt grub-install /dev/sdX # the disk where GRUB should be installed grub-mkconfig -o /boot/grub/grub.cfg exit reboot
How do I uninstall Arch Linux and reclaim its space?
To remove Arch Linux:
- Boot into Windows.
- Open Disk Management (diskmgmt.msc).
- Delete the Linux partitions (the ones you created for Arch: boot, swap, root).
- Extend your Windows partition or create a new volume with the freed space.
- Finally, remove the GRUB entry from UEFI using an elevated command prompt:
diskpart → list disk → sel disk X → list partition → identify the EFI partition (usually FAT32) → sel partition Y → assign letter=Z → exit
Then navigate to Z: and delete the EFI\GRUB folder. Remove the boot entry with bcdedit or a tool like EasyUEFI.
Is it possible to share a partition between Windows and Arch Linux?
You can use a shared NTFS partition for data files (documents, media). However, do not use the same partition for system files or applications – Linux can’t run Windows executables natively (unless using Wine), and Windows can’t use Linux filesystems like ext4 without third-party tools. For a shared data partition, format it as NTFS and both OSes will be able to read/write it.
Why did the guide use mkfs.fat for the boot partition instead of ext4?
UEFI firmware requires the EFI system partition to be formatted with a FAT filesystem (usually FAT32). This is a UEFI specification requirement. The kernel and initramfs are stored on the root partition (ext4), but the bootloader itself (GRUB) places its EFI application in the FAT32 partition.
I don’t want KDE Plasma. How can I install a different desktop environment?
In Step 12, the guide installs plasma (KDE). If you prefer another DE, replace that package with your choice. For example:
- GNOME: sudo pacman -S gnome
- XFCE: sudo pacman -S xfce4
- LXQt: sudo pacman -S lxqt
- Cinnamon: sudo pacman -S cinnamon
You’ll also need a display manager (like SDDM, GDM, LightDM) – SDDM works well with KDE, but GDM is typical for GNOME, etc. Adjust the systemctl enable command accordingly.
What are the most common mistakes during this dual‑boot installation?
- Not disabling Secure Boot, causing boot failure.
- Forgetting to write partition changes in cfdisk (the partitions are not created).
- Mounting the boot partition to the wrong directory (must be /mnt/boot/efi for UEFI).
- Not generating or verifying fstab, leading to boot errors.
- Not enabling NetworkManager, resulting in no network after first boot.
- Not installing grub correctly or forgetting to generate its config.
- Using the wrong partition names in commands.
- Skipping the os-prober step, so Windows never appears in GRUB.
🎉 Congratulations, your setup is complete!
You have successfully configured your system. This setup provides the ultimate flexibility for your daily workflow.
If this guide helped you, subscribe for more step-by-step tutorials.
101 out, I’ll see you in the next one! 🚀
