Restriction modification (RM) systems serve to protect bacteria against bacteriophages. They comprise a restriction endonuclease activity that specifically cleaves DNA and a corresponding methyltransferase activity that specifically methylates the DNA, thereby protecting it from cleavage. Such systems are very common in bacteria. To find out whether the widespread distribution of RM systems is due to horizontal gene transfer, we have compared the codon usages of 29 type II RM systems with the average codon usage of their respective bacterial hosts. Pronounced deviations in codon usage were found in six cases: EcoRI, EcoRV, KpnI, SinI, SmaI, and TthHB81. They are interpreted as evidence for horizontal gene transfer in these cases. As the methodology is expected to detect only one-fourth to one-third of all horizontal gene transfer events, this result implies that horizontal gene transfer had a considerable influence on the distribution and evolution of RM systems. In all of these six cases the codon usage deviations of the restriction enzyme genes are much more pronounced than those of the methyltransferase genes. This result suggests that in these cases horizontal gene transfer had occurred sequentially with the gene for the methyltransferase being first acquired by the cell. This can be explained by the fact that an active restriction endonuclease is highly toxic in cells whose DNA is not protected from cleavage by a corresponding methyltransferase.