If you swap with a different model of motherboard, then you will run into driver issues. If you don't have media to restore it handy, you can try running sysprep before you swap the motherboard, which will purge custom drivers. Not guaranteed to work but is your best shot without a reinstall. Open an elevated command prompt, navigate to \Windows\System32\Sysprep and run :
"Sysprep.exe /oobe /generalize /shutdown
It will shut down your computer when complete. Don't turn it back on before swapping motherboards.
SW is correct regarding OEM Windows licensing. It is bound to the motherboard. Depending on how old your hardware is, you may simply be able to use the key on the license sticker (if you have one). This is not in compliance with MS licensing but it will get you functioning until you can figure something out. Newer hardware doesn't even come with a license key sticker, as SW mentioned it runs a check against an ID on the motherboard.
Windows usually prompts to reactivate with a significant hardware change, but there's usually a 3 day grace period to give you chance to figure something else out.