Amorphous carbon-nitrogen films, a-CNx, deposited by rf-magnetron sputtering in N2 atmosphere were annealed in vacuum at temperatures between 300 and 700 °C. The annealing time was 30 minutes. The modifications on the film microstructure were monitored by infrared spectroscopy (IR), while the composition and the atomic density were determined by Rutherford backscattering spectrometry (RBS), elastic recoil detection analysis (ERDA) and nuclear reaction analysis (NRA). The internal stress was determined by measuring the film-induced bending of the substrate and the hardness was measured by nanoindentation. Atomic force microscopy (AFM) provided the friction coefficient and the surface roughness. The ratio between nitrogen and carbon atomic concentration decreases for temperatures higher than 500 °C, whereas the film density increases with the annealing temperature: 40 % in the temperature range here studied. The behavior of the D and G Raman bands, IR active due to the nitrogen incorporation in the carbon network, suggests a progressive increase of the size of the graphite-like domains. The hardness of the as-deposited a-CNx film is around 2 GPa. However, both hardness and internal stress increase by a factor of three in samples annealed at 700 °C, while the surface roughness and the friction coefficient decrease by a factor of about two.