That depends on the individual technical components. The most efficient way to replace your hard drive on Windows devices is to connect the new hard drive to your PC via USB. This way you can either clone the running system or individual hard disks and partitions to the new hardware without losing any data. You will need an adapter for this. If the new hard drive is a 2.5-inch model or an SSD, a simple SATA-to-USB adapter is sufficient.
It gets a bit more complicated with 3.5-inch hard drives, as they can't be powered via the USB port and you'll need an appropriate enclosure to use them as an external drive. However, you can find a hard drive enclosure with integrated power supply for little money.