Hunger and malnourishment can adversely affect students' performance by lowering their effort and cognition during school hours. We conduct a lab-in-the field experiment, leveraging the extension of Indias school meal program from primary to middle grades, to study the effects of school-based supplementary nutrition on students' cognitive effort in the classroom. Using individual level data on the performance of students in a cognitive task both before and after the extension of the program as well as pre and post meal recess on a school day, we find that the provision of meals improved the cognitive performance of students by 13% to 16%. This result is robust to unobserved heterogeneity in school quality and student ability. Our findings suggest that short-term improvements in classroom attention and effort due to school meals can be a mechanism through which longer-term learning outcomes may improve in developing countries.