How do animals experience brain manipulations? Optogenetics has allowed us to manipulate selectively and interrogate neural circuits underlying brain function in health and disease. However, little is known about whether mice can detect and learn from arbitrary optogenetic perturbations from a wide range of brain regions to guide behavior. To address this issue, mice were trained to report optogenetic brain perturbations to obtain rewards and avoid punishments. Here, we found that mice can perceive optogenetic manipulations regardless of the perturbed brain area, rewarding effects, or the stimulation of glutamatergic, GABAergic, and dopaminergic cell types. We named this phenomenon optoception, a perceptible signal internally generated from perturbing the brain, as occurs with interoception. Using optoception, mice can learn to execute two different sets of instructions based on the laser frequency. Importantly, optoception can occur either activating or silencing a single cell type. Moreover, stimulation of two brain regions in a single mouse uncovered that the optoception induced by one brain region does not necessarily transfer to a second not previously stimulated area, suggesting a different sensation is experienced from each site. After learning, they can indistinctly use randomly interleaved perturbations from both brain regions to guide behavior. Collectively taken, our findings revealed that mice’s brains could “monitor” perturbations of their self-activity, albeit indirectly, perhaps via interoception or as a discriminative stimulus, opening a new way to introduce information to the brain and control brain-computer interfaces.