The electron-HCN collision rate for the excitation of rotational transitions of the HCN molecule is evaluated in comets C/1995 O1 (Hale-Bopp) and C/1996 B2 (Hyakutake). Based on theoretical models of the cometary atmosphere, we show that collisions with electrons can provide a significant excitation mechanism for rotational transitions in the HCN molecule. Computed values of the cross section e-HCN can be as high as 1:3 ; 10 À12 cm 2 , more than 2 orders of magnitude greater than the commonly assumed HCN-H 2 O cross section. For the ground rotational transitions of HCN, the electron-HCN collision rate is found to exceed the HCN-H 2 O collision rate at distances greater than 3000 km from the cometary nucleus of Hale-Bopp and 1000 km from that of Hyakutake. Collisional excitation processes dominate over radiative excitation processes up to a distance of 160,000 km from the cometary nucleus of Hale-Bopp and 50,000 km from that of Hyakutake. Excitation models that neglect electron collisions can underestimate the HCN gas production rates by as much as a factor of 2.