The observable diversity in animal behaviors and perceptions evolves as adaptive responses to various ecological pressures. In order to evolve these diverse behavioral phenotypes, genetic mutations need to occur that alter the connectivity and activity of neural circuits that represent the proximate cause of behavior. My thesis work consisted of two complementary projects that examined how evolution shapes the functional connectivity of neural circuits related to color vision. For my first project, I conducted a series of experiments characterizing the organization of the eye in closely related Heliconius butterflies where males exhibit different mate preferences for females with either white or yellow wing patterns. Both wing color and mate preference are genetically simple traits, which allowed for a targeted examination of how natural genetic variation gives rise to different behaviors. Results revealed a surprising amount of diversity in eye organization across species and sex, with one feature in particular correlated with male mate preference. This feature was a signature of differences in photoreceptor synaptic connectivity, with evidence for inhibition of UV photoreceptors by long wavelength sensitive photoreceptors present in males that prefer yellow females but not in males that prefer white females. My second project used a theoretical, machine learning approach to simulate the evolution of tetrachromatic color vision from a trichromatic ancestor. The results of my simulations showed that the learning trajectories and specific computational mechanisms used for color vision in these circuits were predictable and depended on the specific network architecture of the original trichromatic network. Together, my results show how an evolutionary perspective and approach can lead to insights into how neural circuits are organized and function to produce adaptive behaviors.