Virus are remarkable self-assembled nanobiomaterial-based machines, exposed to a wide range of pH values. Extreme pH values can induce dramatic structural changes, critical for the function of the virus nanoparticles including assembly and genome uncoating. Tuning cargo - capsid interactions is essential for designing viral-based delivery systems. Here we show how pH controls the structure and activity of wild-type simian virus 40 (wtSV40) and the interplay between its cargo and capsid. Using cryo-TEM and solution X-ray scattering, we found that wtSV40 was stable between pH 5.5 and 9, and only slightly swelled with increasing pH. At pH 3, the particles aggregated, while capsid protein pentamers continued to coat the virus cargo but lost their positional correlations. Infectivity was only partly lost after the particles had been returned to pH 7. At pH 10 or higher, the particles were unstable, lost their infectivity, and disassembled. Using time-resolved experiments we discovered that disassembly began by swelling of the particles, poking a hole in the capsid through which the genetic cargo escaped, and followed by a slight shrinking of the capsids and complete disassembly. These findings provide insight into the fundamental intermolecular forces, essential for SV40 function, and for designing virus-based nanobiomaterials, including delivery systems and antiviral drugs.