Codon pair bias is a remarkably stable characteristic of a species. Although functionally uncharacterized, robust virus attenuation was achieved by recoding of viral proteins using underrepresented codon pairs. Because viruses replicate exclusively inside living cells, we posited that their codon pair preferences reflect those of their host(s). Analysis of many human viruses showed, however, that the encoding of viruses is influenced only marginally by host codon pair preferences. Furthermore, examination of codon pair preferences of vertebrate, insect, and arthropod-borne viruses revealed that the latter do not utilize codon pairs overrepresented in arthropods more frequently than other viruses. We found, however, that codon pair bias is a direct consequence of dinucleotide bias. We conclude that codon pair bias does not play a major role in the encoding of viral proteins and that virus attenuation by codon pair deoptimization has the same molecular underpinnings as attenuation based on an increase in CpG/TpA dinucleotides.