To identify potential risk factors for pre- and postoperative seizures and epilepsy in children with congenital heart disease. Retrospective cohort study of neonates and infants <3 months of age with congenital heart disease who underwent cardiopulmonary bypass from November 24, 2006, until June 1, 2015. Children with seizures were classified based on time of occurrence into early preoperative, early postoperative, and late postoperative. Children with recurring seizures 30 days after cardiac surgery met criteria for epilepsy. 247 patients completed follow-up; 2.4% had seizures early preoperation and 1.6% early postoperation. Late postoperative epilepsy occurred in 5.3% of the cohort. The majority of seizures in the late postoperative epilepsy group started after 1 year of age (mean 1.53 years, range = 0.18-4.7 years). One of the 13 patients with epilepsy had a seizure during their intensive care unit hospitalization. Potential risk factors for seizures included brain injury (P < .001), high-risk surgery (Society of Thoracic Surgeons-European Association for Cardio-Thoracic Surgery score ≥3, P = .024), and low birth weight (P < .04). Infants with stroke were more likely to develop epilepsy (P = .04). Presence of seizures was associated with increased length of stay (P < .001). Our study suggests an association between children with congenital heart disease diagnosed with stroke in the neonatal/infancy period and the development of epilepsy. These children may not have prior early pre- and postoperative seizures. Risk factors for seizures include brain injury, high-risk surgery, and lower birth weight. Seizures were associated with an increased length of stay but did not necessarily lead to subsequent epilepsy.