Releasing the packaged viral DNA into the host cell is an essential process to initiate viral infection. In many double-stranded DNA bacterial viruses and herpesviruses, the tightly packaged genome is hexagonally ordered and stressed in the protein shell, called the capsid. DNA condensed in this state inside viral capsids has been shown to be trapped in a glassy state, with restricted molecular motion in vitro. This limited intracapsid DNA mobility is caused by the sliding friction between closely packaged DNA strands, as a result of the repulsive interactions between the negative charges on the DNA helices. It had been unclear how this rigid crystalline structure of the viral genome rapidly ejects from the capsid, reaching rates of 60,000 bp/s. Through a combination of single-molecule and bulk techniques, we determined how the structure and energy of the encapsidated DNA in phage λ regulates the mobility required for its ejection. Our data show that packaged λ-DNA undergoes a solid-to-fluid-like disordering transition as a function of temperature, resulting locally in less densely packed DNA, reducing DNA-DNA repulsions. This process leads to a significant increase in genome mobility or fluidity, which facilitates genome release at temperatures close to that of viral infection (37 °C), suggesting a remarkable physical adaptation of bacterial viruses to the environment of Escherichia coli cells in a human host.