We designed and validated a system for determining the state of sleep or wakefulness in both term and preterm infants. The system is based on independent assessments of behavioral and electroencephalographic (EEG) patterns. Overall agreement between observers in coding individual behavioral patterns was 77.6%. Agreement between observers in coding EEG patterns was 87.4%. Designation of an infant's state is made by combining concurrent behavioral and EEG scores into a single two-number code. The distribution of sleep state for eight infants greater than 36 wk postconceptional age (PCA) was the following: quiet sleep (QS), 30.4%; active sleep (AS), 50.0%; indeterminate sleep (IS), 11.4%, and wakefulness (W), 7.5%. The distribution of sleep state for 15 infants less than 36 wk PCA was as follows: QS, 18.9%; AS, 52.9%; IS, 16.4%; and W, 10.5%. Our experience with the system suggests that it is useful for relating sleep state to physiologic variables during neonatal experimental studies.