Introduction: Diabetes mellitus (DM) and chronic kidney disease (CKD) are comorbidities of great therapeutic and prognostic importance in patients with coronary artery disease (CAD). Knowledge about their prevalence, associated factors and influence on optimal medical therapy are needed to best manage this population. Methods: This is a unicentric cross-sectional analysis of 869 patients enrolled in a CAD registry in Brazil. To be included, patients needed to have a previous coronary artery revascularization procedure (either percutaneous or surgical), documented previous acute coronary syndrome, or known coronary stenosis greater than 50%. CKD was defined as creatinine clearance < 60 mL/min. DM was defined as prescription of glucose-lowering drugs or a HbA1c > 6.5%. Results: Overall, mean age was 64.7 years, 261 (30%) were women, 528 (61%) had previous myocardial infarction, and 547 (63.4%) had a previous revascularization procedure. DM was prevalent in 449 (51.7%) patients and CKD in 280 (32.2%). Both comorbidities were concomitant in 151 (17.4%) patients. On multivariate analysis, CKD was correlated to female sex (OR 2.94; 95%CI 1.88-4.67), age (OR 1.20; 95%CI 1.16-1.23), BMI (OR 0.80, 95%CI 0.76-0.84), and HDL-cholesterol (OR 0.97; 95%CI 0.96-0.99). DM was associated with age (OR 1.02, 95%CI 1.00-1.04), BMI (OR 1.05, 95%CI 1.01-1.08), high blood pressure (OR 2.1, 95%CI 1.39-3.21), and heart rate (OR 1.02, 95%CI 1.00-1.03). Concomitant presence of CKD and DM was associated with age (OR 1.09, 95%CI 1.06-1.13) and left ventricular ejection fraction (OR 0.97, 95%CI 0.95-0.98). Patients with DM were more likely to receive ACE inhibitors or ARBs (79.3% x 67.1%, p< 0.001) and calcium channel blockers (41.9% x 31.2%, p=0.001). Patients with DM and CKD had higher use of nitrates (38.4% x 25.6%, p=0.002). There was no difference in the prescription of antithrombotic drugs, beta-blockers or statins between groups. Conclusion: DM and CKD are both very prevalent comorbidities in patients with CAD. They are associated with age and risk markers such as high blood pressure and lower left ventricular ejection fraction. Although typically these populations are undertreated in others registries, this fact was not observed in our study.