The dendrites of mammalian pyramidal neurons contain a rich collection of active conductances that can support Na+ and Ca2+ action potentials (for a review see ref. 1). The presence, site of initiation, and direction of propagation of Na+ and Ca2+ action potentials are, however, controversial, and seem to be sensitive to resting membrane potential, ionic composition, and degree of channel inactivation, and depend on the intensity and pattern of synaptic stimulation. This makes it difficult to extrapolate from in vitro experiments to the situation in the intact brain. Here we show that two-photon excitation laser scanning microscopy can penetrate the highly scattering tissue of the intact brain. We used this property to measure sensory stimulus-induced dendritic [Ca2+] dynamics of layer 2/3 pyramidal neurons of the rat primary vibrissa (Sm1) cortex in vivo. Simultaneous recordings of intracellular voltage and dendritic [Ca2+] dynamics during whisker stimulation or current injection showed increases in [Ca2+] only in coincidence with Na+ action potentials. The amplitude of these [Ca2+] transients at a given location was approximately proportional to the number of Na+ action potentials in a short burst. The amplitude for a given number of action potentials was greatest in the proximal apical dendrite and declined steeply with increasing distance from the soma, with little Ca2+ accumulation in the most distal branches, in layer 1. This suggests that widespread Ca2+ action potentials were not generated, and any significant [Ca2+] increase depends on somatically triggered Na+ action potentials.