In this protocol we detail the steps to perform ex-vivo brain slice electrophysiology and optogenetic stimulation.