This ImageJ plugin allows to detect and count dendritic spines, to segment spine heads, to trace spine necks, to obtain quantitative morphological measurements.
Spine detection and spine heads segmentation use algorithms from the plugin 3D ImageJ Suite.
Spine necks tracing uses algorithms from the plugin SNT.
You'll find more informations on the imagej.net page.