With humanity's seemingly insatiable desire for data, archiving it safely has become a bit of a problem. The various means we've been using all have tradeoffs in terms of energy and space efficiency, many of which change as the technologies mature. And, as new tech moves in, many earlier storage media become obsolete—to the point where it's essentially impossible to read some old formats.

What if there were a storage medium that would be guaranteed to be readable for as long as humanity's around and didn't need any energy to maintain? It's called DNA, and we've become very good at both making and decoding it. Now, two researchers have pushed the limits of DNA storage close to its theoretical maximum using a coding scheme that was originally designed for noisy communication channels. The result: an operating system and some movies were stuffed into genetic code at a density of 215 Petabytes per gram.

The new work comes courtesy of Yaniv Erlich and Dina Zielinski, who work at the New York Genome Center. They have built on a variety of earlier work. Not much challenge is involved in putting data into DNA: each place in the sequence can hold one of four bases: A, T, C, or G. That lets us write two bits per position. The trick is getting things back out reliably.

Nothing about DNA is 100 percent accurate or even as close to the accuracy we've come to expect from our electronic bit storage media. Simply synthesizing DNA of a desired sequence will sometimes result in an error, as will amplifying it or decoding it again. And some specific sequences are especially error prone, like long runs of a single base (like TTTTTTTTTT) or stretches that are a mix of Gs and Cs. So any encoding method has to be robust to these issues.

Fortunately, we've already developed encoding algorithms that stand up to data loss. The authors went with Fountain codes, which allow packet-based data to be transmitted over networks where some of the packets get lost. Fountain encoded data is minimally redundant, in that it doesn't hold duplicates of all the original data. Still, it allows the original message to be reconstructed even if some fraction of the packets are lost. The more packets you send, the easier it becomes to reconstruct the original data.

So the authors devised a system in which data is fountain encoded, creating lots of small packets. These packets are then encoded as DNA sequences. An algorithm then scans the results and eliminates any DNA sequences that are going to cause problems, like ones with a long run of As. Since you can always make more packets, this is repeated until there's enough DNA sequences to give you the sort of robustness you'd want. For this work, the data portion of the DNA was 128 bases long and held 32 bytes of data. Additional bases contained information about the encoding, error correction codes, and sequences that allowed the DNA to be copied and read out.

The system was fed a 2.1MB compressed archive that contained some movies, a simple GUI operating system, and assorted other files. The system spit out 72,000 segments of DNA, which had a redundancy of just 7 percent, which is about 86 percent of the theoretical maximum for DNA storage. These DNA segments were then ordered from a company, which delivered them for testing.

That testing showed that, on a variety of levels, the system worked. The authors could reconstruct their archive using DNA sequencing. And, when they randomly eliminated some of the resulting sequences, the encoding and error correction still allowed the data to be reconstructed. They also diluted things down to see where the concentration of DNA got so low that the system failed. This led to their estimate that they were storing 215 Petabytes per gram of DNA. The authors estimate that their original order of DNA would be good for over 1015 reads of the data.

Plus you could stretch it out much further. PCR amplification of DNA isn't ideal for data storage, since it introduces errors and some sequences won't amplify. But the fountain encoding is designed to handle these problems, so the researchers sent the original material through nine rounds of dilution and PCR. The message still came through. At that point, it's fair to say that the system allows for infinite reads of the DNA.

So what are the problems? Each time you want to read the data, you need to be prepared to wait about a day and spend some money. And the costs are even greater to put the data into DNA in the first place—the authors estimate that at a brain-exploding $3,500 per Mbyte (and you thought SSDs were pricey!).

Of course, the authors note that part of the expense is that the biologists who typically order DNA from these companies want it to arrive error free. If you speed up some of the steps and skip the quality control, the price should go down. Error rates would probably go up, but this system deals with error nicely.

But the key is that, unless civilization reverts to the point where we can no longer read DNA or implement a fountain algorithm, the data will be accessible. (And if we regress technologically to the point where we can't do these things, who cares about the data at that point?) And it's doubtful that any other form of storage can offer that sort of promise.

Science, 2017. DOI: 10.1126/science.aaj2038 (About DOIs).

Correction: fixed a Gigabyte/Megabyte typo.