We show that, for any integers γ, β, class-preserving automorphisms of the HNN extension B, t : t −1 h γ t = h β of a finitely generated nilpotent or free group B are all inner. It follows from Grossman's result that outer automorphism groups of such conjugacy separable HNN extensions are residually finite.