If you get a message that states Windows can't be activated, the following are a few reasons why it might not have worked, along with some possible solutions.
A different product key or version of Windows was used during repair
If your PC was repaired or rebuilt, it's possible that a different version of Windows was installed. Or, if a different product key was used for your PC during repair, that key might be blocked if it was used on more PCs than allowed by the Microsoft Software License Terms.
If Windows was activated before your PC was repaired or rebuilt, re-entering the product key included with your PC or original copy of Windows might resolve the problem. Also, try reinstalling your original version of Windows.
To activate Windows, you need either a 25-character Windows product key or a Windows digital license.
One copy of Windows was installed on multiple PCs
If you have one copy of Windows and installed it on more than one PC, activation might not work because the product key has already been used, or it's used on more PCs than allowed by the Microsoft Software License Terms.
If your product key is being used on more PCs than allowed by the Microsoft Software License Terms, you must buy a new product key or copy of Windows for each of your PCs to activate them.
If you have a counterfeit copy of Windows that wasn't published and licensed by Microsoft, activation won't work because Microsoft won't be able to match your PC's hardware profile with the 25-character product key.
The Microsoft How to Tell website can help you determine whether your copy of Windows is counterfeit. If it is, you must buy a new copy of Windows.
A used PC
If you bought a used PC with Windows already installed, it's possible that the product key is being used on more PCs than allowed by the Microsoft Software License Terms.
Ask the seller you bought the used PC from for the original Windows DVD and product key. If they aren't available, or if you tried them and still can't activate your PC, you must buy a new product key or another copy of Windows.
If you made substantial hardware changes to your PC, such as replacing your hard drive or motherboard, Windows might no longer be activated.