The extensive dendritic arbor of neurons is thought to be actively involved in the processing of information. Dendrites contain a rich diversity of ligand- and voltage-activated ion channels as well as metabotropic receptors. In addition, they are capable of releasing calcium from intracellular stores. Under specific conditions, large neurons produce calcium spikes that are locally restricted to a dendritic section. To investigate calcium signaling in dendrites, we introduce TubuTag, a genetically encoded ratiometric calcium sensor anchored to the cytoskeleton. TubuTag integrates cytoplasmic calcium signals by irreversible photoconversion from green to red fluorescence when illuminated with violet light. We used a custom two-photon microscope with a large field of view to image pyramidal neurons in CA1 at subcellular resolution. Photoconversion was strongest in the most distal parts of the apical dendrite, suggesting a gradient in the amplitude of dendritic calcium signals. As the read-out of fluorescence can be performed several hours after photoconversion, TubuTag will help investigating dendritic signal integration and calcium homeostasis in large populations of neurons.