You would need to buy a valid retail license for Windows 7.
At least in the U.S. and Canada, the OP can buy an OEM version for a huge discount. Microsoft will not provide support, and the OEM version will not perform upgrades, only clean installs (although its key can be used to activate an upgrade performed with a retail or Enterprise edition).
In the old days, Microsoft would insist that OEM versions be sold with hardware, but that is no longer the case. You are free to buy a copy by itself.