The intensity of pain after cardiac surgery is often underestimated, and inadequate pain control may be associated with poorer quality of recovery. The aim of this investigation was to examine the effect of intraoperative methadone on postoperative analgesic requirements, pain scores, patient satisfaction, and clinical recovery. Patients undergoing cardiac surgery with cardiopulmonary bypass (n = 156) were randomized to receive methadone (0.3 mg/kg) or fentanyl (12 μg/kg) intraoperatively. Postoperative analgesic requirements were recorded. Patients were assessed for pain at rest and with coughing 15 min and 2, 4, 8, 12, 24, 48, and 72 h after tracheal extubation. Patients were also evaluated for level of sedation, nausea, vomiting, itching, hypoventilation, and hypoxia at these times. Postoperative morphine requirements during the first 24 h were reduced from a median of 10 mg in the fentanyl group to 6 mg in the methadone group (median difference [99% CI], -4 [-8 to -2] mg; P < 0.001). Reductions in pain scores with coughing were observed during the first 24 h after extubation; the level of pain with coughing at 12 h was reduced from a median of 6 in the fentanyl group to 4 in the methadone group (-2 [-3 to -1]; P < 0.001). Improvements in patient-perceived quality of pain management were described in the methadone group. The incidence of opioid-related adverse events was not increased in patients administered methadone. Intraoperative methadone administration resulted in reduced postoperative morphine requirements, improved pain scores, and enhanced patient-perceived quality of pain management.