Student attendance is both a critical input and intermediate output of the education production function. However, the malleable classroom-level determinants of student attendance are poorly understood. We estimate the causal effect of class size and observable teacher qualifications on student attendance rates by leveraging the random classroom assignments made by Tennessee's Project STAR (Student/Teacher Achievement Ratio) class size experiment. A ten-student increase in class size raises the probability of being chronically absent by about three percentage points (21%). For black students, random assignment to a black teacher reduces the probability of chronic absence by 3.1 percentage points (26%). These suggest that a small, but nontrivial, share (about 5%) of class-size and race-match effects on student achievement are driven by changes in students' attendance habits.