Consider that one want to keep a backup of some data by placing a media in a secret place (under earth, in a rock, in a wall...). What would be the best media with the best long term data stability (like 50 years or more) for such an experiment and why : a USB key, a DVD, a SD card, a HDD, a SSD or others, considering that no access will be performed on this media for 50 years.
Your best option is M-Disk. You also should consider availability of a DVD players at the moment of access in future, for example consider reading a magnetic tape or a punched tape today. Not a trivial task. Same goes for all other options, of course.
Your second best option is Blu-ray disk, which is superior to DVD in terms of longevity with estimation of about 100-150 years. But you should consider a good package for that type of disk, since it's estimation goes for a living-room quality storage type. See also.
USB, SD, SSD, HDD are all relatively unreliable in terms of long-term storage and you can expect about 10 years before degradation of data starts.
A USB key, SD card, and an SSD are all flash memory. An HDD is magnetic, and a DVD is optical. So this question becomes flash vs magnetic vs optical.
I would say optical media (DVD, CD, etc.) would be best for this scenario. While all three of these data mediums are non-volatile (they don't require a continuous power input to hold their contents), I think that optical media will degrade less over long periods of time (assuming that you're keeping this medium in a sealed location where there are few outside forces acting on it). Flash and magnetic media use electric/magnetic charges to hold data, which may degrade over time. The charge may get weaker with time. Optical media, especially if you are using a read-only disc, will be much more reliable because the laser used to burn the data into the medium actually creates a permanent change.
Of course, I could be talking out of my ass right now. In which case, please correct me. It'll be a good learning opportunity as well.
I found a nice chart which shows the expectations of storage longevity in used and unused cases.
(I don't claim that the data shown in this picture is 100% correct. But the creators provide sources to every data of storage type.)
Keep in mind that the tricky part is how to access the data in 100 years if the technologies to read it back is only available in museums.
Some of their sources