We investigate hydrodynamic instability of a steady planar detonation wave propagating in a circular tube to three-dimensional linear perturbations, using the normal mode approach. Spinning instability is identified and its relevance to the well-known spin detonation is discussed. The neutral stability curves in the plane of heat release and activation energy exhibit bifurcations from low-frequency to high-frequency spinning modes as the heat release is increased at fixed activation energy. With a simple Arrhenius model for the heat release rate, a remarkable qualitative agreement with experiment is obtained with respect to the effects of dilution, initial pressure and tube diameter on the behaviour of spin detonation. The analysis contributes to the explanation of spin detonation which has essentially been absent since the discovery of the phenomenon over seventy years ago.