Using the Yebes 40m radio telescope, we report the detection of a series of seven lines harmonically related with a rotational constant B0 = 1295.81581 ± 0.00026MHz and a distortion constant D0 = 27.3 ± 0.5Hz towards the cold dense cloud TMC-1. Ab initio calculations indicate that the best possible candidates are the cations HC5NH+ and NC4NH+. From a comparison between calculated and observed rotational constants and other arguments based on proton affinities and dipole moments, we conclude that the best candidate for a carrier of the observed lines is the protonated cyanodiacetylene cation, HC5NH+. The HC5N/HC5NH+ ratio derived in TMC-1 is 240, which is very similar to the HC3N/HC3NH+ ratio. Results are discussed in the framework of a chemical model for protonated molecules in cold dense clouds.