Go to ...

RSS Feed

September 23, 2020

Selling a Windows PC – How to prepare


If you want to sell or give away a Windows computer, be it a desktop, a laptop or a tablet, there are a few things to consider. Will you sell it with Windows licensed and activated, will you just delete your user account but let all software and apps remain intact? Or, would you prefer to wipe the disks clean and erase all traces of your prior presence and use?

Let’s look at your options. The instructions given apply to OEM and Retail licenses, as well as to Multiple Activation Key (MAK) licenses which are shown as Retail license. These instructions do not apply to Key Management Service (KMS) licenses.

Please notice: screenshots used are from an activated Hyper-V Windows 10 Pro Insider Preview virtual machine. The instructions apply to all physical and virtual machines.
OEM or Retail License?

Open Settings app, select System > About. Under Device specifications, check the Product ID. If the last three characters of it is OEM, your license is an OEM license, as for instance on computers bought with preinstalled Windows:

Click the screenshots to open enlarged in a new tab.

Three last characters in a Retail (or MAK) license Product ID are digits:

OEM License – Remove from MS Account

According to Windows EULA, an OEM license cannot be transferred to another device. Thus, it is better to leave it intact, not to deactivate it. After we are done, the new owner gets the specific Windows 10 edition automatically activated. If your OEM license is linked to a Microsoft account, only thing you need to do now is to remove the device from your Microsoft account. Go to https://account.microsoft.com/devices/, select your device, click the three dots on right top corner, and remove the device:

Weirdly, Hyper-V virtual machines are showing a Remove laptop message!

Retail License – Deactivate Windows
Skip this step, if you want to sell / give away the device licensed and activated.

A Retail license can be transferred, and reused on another device. It is a good idea to unistall the product key and deactivate Windows. This allows you to reuse the key and license on another device. First thing to do is to check that your Retail license is linked to your Microsoft account (it’s the only way to transfer it). See Windows 10 Digital License – How to transfer, and scroll down to Taking care of Digital Licenses to see how. When done, check that the device is listed on your account on https://account.microsoft.com/devices/

Open an elevated Command Prompt. Enter the following command to open Windows Software License Manager and show license properties:

slmgr /dlv

Check the Activation ID:

Back to the Command Prompt, enter the following command to remove the Windows license, and deactivate it. Replace ID with the actual 32-bit hexadecimal Activation ID:

slmgr /upk ID

PC sold with software

If your intention is to sell or give away PC with existing Windows installation and installed software (strongly not recommended!), run the Windows System Preparation Tool (sysprep.exe) from the C:\Windows\System32\Sysprep folder. Accept the defaults, and click OK;

Sysprep will run, and then Windows restarts to the OOBE. When the region selection screen is shown, press SHIFT + F10 to open Command Prompt. This activates various WIN-key shortcuts, and transforms the Ease of Access button at the bottom left corner to a Settings button. Close the Command Prompt window, then open Settings. Go to Accounts > Family & other users, select an existing user account, and remove it:

Repeat and remove all user accounts. When you’re done, close the Settings app. Press WIN + E to open File Explorer. Browse to C:\Users, and check that only defaultuser0 and Public folders are shown. If there are any user folders for accounts you removed, manually delete them. Check the Public folder and delete any documents, pictures and other personal data possibly still in its subfolders.

Close File Explorer. Press WIN + R to open Run dialog, type CLEANMGR, and press Enter to open Disk Clean-up tool. Please notice, that it usually opens behind the Region selection screen, and you might need to press and hold ALT + TAB, and select Disk Clean-up:

In Disk Clean-up, select Clean-up system files (again, it might open behind Region selection screen). Select everything, click OK to clean the disk. When done, press WIN + R, and type following command:

shutdown -s -t 0

Press Enter to shut down Windows. It is now ready to be sold or given away. When new owner starts the device first time, it will boot to OOBE Region selection. New owner needs then to go through OOBE to setup the device.

PC sold without software

The recommended option is to sell or give away the device totally cleaned, disks wiped, and all traces of previous owner removed. I recommend using third party software to wipe the disk. Check this list for some free tools.

Disconnect all external devices except mouse, keyboard and a display. Boot the device from any Windows 10 install media, or, in case of using a third party disk wipe tool, from its boot media. In these instructions, I will show a really effective method using normal Windows install media, but this method is, although quite effective, not as good as special disk wipe tools.

When booted from Windows install media, press SHIFT + F10 in Region selection screen to open Command Prompt. Enter the command DISKPART to run Disk Partition Utility (#1 in screenshot). Enter the command list disk to list all present disks (#2). In this example, my demo virtual machine only has one disk. Check the disk number(s), and under GPT column if the disk is GPT partitioned (GPT column shows an asterisk), or MBR (empty GPT column) (#3).

Repeat the following steps for every internal disk:

Select disk with command sel disk X, where X is the disk number (#4). Wipe the disk clean with the command clean all (#5). If the disk is a GPT disk, convert it to an MBR disk with the command convert MBR (#6), or if the disk is an MBR disk, convert it to GPT with the command convert GPT. Create a new empty partition with the command create part primary (#7). format it with the command format (#8). Again, wipe the disk with the command clean all (#9). Finally, convert the disk back to its original type, use the command convert GPT (#10) if the disk was originally a GPT disk (see #3), or the command convert MBR if the disk was an MBR disk.

The above process makes data recovery almost impossible, because it is quite hard for the new owner to try to use recovery tools to get to your erased personal data. Wiping the disk, converting it, creating partition which will be formatted immediately, wiping the disk again, and finally converting it back its original type.Yet, as I mentioned earlier, a third party disk wipe tool is what I recommend.

When you have repeated the above steps for every internal disk, close the command prompt. Continue installing Windows 10 normally. I recommend installing the Home edition, because the new owner can easily upgrade it to any other preferred edition. If you install for instance  Pro edition and new owner wants Home, it cannot be downgraded.

When installation reaches the Region selection screen, press SHIFT + F10 to open Command Prompt. Enter the following command and press Enter to shut down Windows:

shutdown -s -t 0

That’s it. Your PC is now ready to be sold or given to its new owner. The next boot will show OOBE Region selection, and the new owner needs to go through OOBE to setup WIndows for an initial login to the desktop.

Kari

Author: Kari Finn

A former Windows Insider MVP, Kari started in computing in the mid 80’s writing code for VAX / VMS systems. Since then, he’s worked in a variety of IT positions. He specializes in Windows image capture, customization, repair and deployment as well as Hyper-V virtualization. Kari is a proud Team Member at number #1 Windows site TenForums.com.

Leave a Reply

More Stories From Activation