Whether it’s for nostalgia or to run old software, there are benefits to running a Windows XP machine—for the right reasons. Obviously, it’s not recommended to run Windows XP as your only operating system, as it’s outdated, unsupported, and full of security risks.

Thankfully, it’s entirely possible to set up a Windows XP virtual machine for free. While the official methods require a Windows 7 PC, you can use Windows 10 and other operating systems, although this method requires a bit of a workaround. To get Windows XP running as a virtual machine, you’ll have to follow these instructions carefully.

Downloading Windows XP and Extracting Installation Files

To begin using your Windows XP virtual machine, you’ll need to use a PC running Windows 10, with virtualization enabled in the BIOS or UEFI settings. You can use another operating system, but these instructions have been designed with Windows 10 in mind. 

The operating system you use will also need to be supported by VirtualBox, the software we’ll be using to run Windows XP.

  • If your PC is ready, download the Windows XP Mode EXE file from the Microsoft website (named WindowsXPMode_en-us.exe). If the file is no longer hosted on Microsoft, you can download it from CNET. Once downloaded, don’t run the file. This XP installer is only supported by Windows 7, so we’ll need to extract the files you’ll need from it to get XP to run on Windows 10.If your PC doesn’t already have it installed, download and install 7-Zip before you proceed. Once 7-Zip is installed, locate your Windows XP installer file in Windows File Explorer, then right-click the file. From there, click 7-Zip > Open archive > Cab to open the EXE file in the 7-Zip File Manager.

  • In the 7-Zip File Manager, double-click the Sources folder, then double-click the xpm file. This will open a second 7-Zip File Manager window containing your Windows XP virtual machine files. Select the contents before clicking the Extract button.

  • Choose a suitable location for your files. You may need to create a new folder before you do this. Once you’re ready, click OK to extract the files to your PC.

  • Open the folder containing your Windows XP files in Windows File Explorer. Locate the VirtualXPVHD file, right-click > Rename, then change the name from VirtualXPVHD to VirtualXP.VHD, adding a period between XP and VHD.

Adding the VHD file extension changes this file to a virtual hard disk file, supported by VirtualBox, allowing you to run Windows XP as a virtual machine.

Setting Up a Windows XP Virtual Machine Using VirtualBox

After you’ve extracted your Windows XP download files, you’re ready to begin setting it up as a virtual machine.

  • First, you’ll need to download and install VirtualBox. Once installed, open VirtualBox and click the New button to begin creating a new virtual machine.

  • In the Create Virtual Machine window, click the Expert Mode button at the bottom. Type Windows XP in the Name box to automatically configure the settings to suit XP.  Double-check that the Version is set to Windows XP (32-bit), then set the Memory Size to around 512MB or higher. You can go higher, although XP will be fine with less.

  • In the Hard Drive section of the Create Virtual Machine window, select Use an existing hard disk file. Press the folder icon next to it, then click Add in the Hard Disk Selector window.

  • Locate the VirtualXP.VHD file, then click Open to add it. Once VirtualXP.VHD appears in the Hard Disk Selector window, select it, then press the Choose button.

  • Once you’ve returned to the Create Virtual Machine window, double-check your settings are correct before pressing the Create button.

Final VirtualBox Configuration and Windows XP Testing

Your newly created Virtual XP simulator will appear as a virtual machine in the VirtualBox Manager. You’ll need to make a few changes before you begin running it, however.

  • In VirtualBox Manager, select your XP virtual machine and click the Settings button to begin configuration.

  • Click the System tab first. Under Boot Order, uncheck Floppy, then reorder the items into the following order using the side arrows: Hard Disk, Optical, Floppy, Network.

  • Click the Display tab. Increase the Video Memory from 16MB to 128MB using the slider in the Screen section.

  • Once your settings are correct, click OK to save your Windows XP virtual machine settings. You can now run your XP machine for the first time by clicking the Start button.

  • You’ll need to confirm some initial XP settings when you run XP for the first time as a virtual machine, such as your keyboard layout and time zone. Confirm these settings at each stage by pressing the Next button.

  • Give your XP virtual machine a name, as well as provide an Administrator password. You can leave the password blank if you’d prefer. Click Next to proceed.

  • After confirming your time and date settings, XP will complete the setup process and reboot. Once this has completed, click Devices > Insert Guest Additions CD Image in your VirtualBox window. This will install additional drivers and settings to make your XP experience work better in VirtualBox.Follow the setup process, pressing Continue Anyway to any driver warnings that appear.

  • With VirtualBox Guest Additions installed, click Finish to reboot your XP virtual machine.

The Windows XP virtual machine that loads at this point can only be used for 30 days as it lacks a valid license. If you can find your Windows license key for Windows XP (from an older PC, for instance), you may be able to add it to your virtual machine directly, although it may still not activate.

To bypass this, create a snapshot of your virtual machine immediately after creating it.

  • With your XP virtual machine running, click Machine > Take Snapshot. Give your initial Windows XP Snapshot a name before pressing the OK button. If you want to restore your virtual machine to this snapshot later, press the menu icon next to your XP virtual machine in VirtualBox Manager and select Snapshots. From here, select your snapshot before pressing the Restore button.

Restoring your Windows XP virtual machine using a snapshot will reset the clock, allowing you to use XP indefinitely, although you will lose any files or software you’ve installed after this point.

Running Newer Operating Systems In VirtualBox

Once your thirty days are up, don’t forget to revert back to your initial VirtualBox snapshot to reset the clock on your XP licensing if you want to keep testing it.

You can only do so much with a Windows XP simulator like this, but if you want to keep testing, you can try out other operating systems as VirtualBox virtual machines. For instance, if you want to give Linux a try, install Ubuntu in VirtualBox instead.