The combination of optogenetic control and fMRI readout in the brain is increasingly used to assess neuronal networks and underlying signal processing. However, how exactly optogenetic activation or inhibition reproduces normal physiological input has not been fully unraveled. To assess details of temporal dynamics of the hemodynamic response, temporal resolution in rodent fMRI is often not sufficient. Recent advances in human fMRI using faster acquisition schemes cannot be easily translated to small animals due to smaller dimensions, fast physiological motion, and higher sensitivity to artefacts. Here, we applied a one dimensional line scanning acquisition with 50 ms temporal resolution in rat somatosensory cortex. We observed that optogenetic activation reproduces the hemodynamic response upon sensory stimulation, but shows a 160 to 340 ms earlier onset of the response. This difference is explained by direct activation of all opsin-expressing and illuminated cortical layers, while hemodynamic response to sensory stimulation is delayed during intracortical transmission between cortical layers. Our results confirm that optogenetic activation is a valid model for physiological neuronal input, and that differences in temporal behavior of only a few hundred milliseconds can be resolved in rodent fMRI.