The average life of a hard drive depends on a lot of things, like the brand, type, size, and interface method, but you're looking at about four years on average. Online backup service Backblaze studied the drives in their infrastructure and found about 80% of them survived for four years. Because hard disk drives have moving parts (electromagnetic platters), they are more prone to physical damage. On the other hand, because solid state drives don’t have any moving parts, they are less susceptible to physical damage. This does not mean they are automatically safe, however.
Data stored on HDDs will naturally degrade over a period of several years, even if kept in optimum conditions. Solid state drives, which have become extremely popular in laptops and desktops due to their faster speeds, are different. You may hear people say that you have to be careful with SSDs because they have a limited number of reads and writes. In reality, consumer SSDs actually last a really, really long time under normal use. TechReport’s SSD endurance test showed that a lot of those fears are over-blown, and even consumer SSDs managed to survive writing and reading well over 700TB of data.
If you’re looking to store data long term, then, it is best to opt for a hard disk drive. Humidity and temperature, while still affecting HDDs, are much more damaging to SSDs. However, when sing HDDs, extra care must be taken not to drop them.