• Cryo-EM structure of Pam5 TerS reveals a nonameric ring with a radially symmetric spiral architecture.
• Pam5 TerS recognizes a specific 21-bp DNA sequence within its own gene via its N-terminal helix-turn-helix (HTH) domain.
• Pam1 TerS, from a cyanophage infecting the same host, binds DNA in a sequence-independent manner.
• Cyanophages infecting the same host can employ divergent DNA recognition strategies for genome packaging.