Methods to label neurons and to monitor their activity with genetically encoded fluorescent reporters have been a staple of neuroscience research for several years. The recent introduction of photoswitchable ion channels and pumps, such as channelrhodopsin (ChR2), halorhodopsin (NpHR), and light-gated glutamate receptor (LiGluR), is enabling remote optical manipulation of neuronal activity. The translucent brains of zebrafish offer superior experimental conditions for optogenetic approaches in vivo. Enhancer and gene trapping approaches have generated hundreds of Gal4 driver lines in which the expression of UAS-linked effectors can be targeted to subpopulations of neurons. Local photoactivation of genetically targeted LiGluR, ChR2, or NpHR has uncovered novel functions for specific areas and cell types in zebrafish behavior. Because the manipulation is restricted to times and places where genetics (cell types) and optics (beams of light) intersect, this method affords excellent resolving power for the functional analysis of neural circuitry.