© 2016 Elsevier Inc. In patients with chronic heart failure (HF), cognitive impairment (CI) is associated with poorer treatment adherence and higher readmission and mortality rates. Previous studies suggest that atrial fibrillation (AF) could impair cognitive function. This study sought to assess the association between permanent AF (permAF) and CI in patients with HF. We evaluated cognitive function in 881 patients with stable HF (73 ± 11 years, 44% women, 48% with preserved ejection fraction) using the Mini-Mental State Examination test (n = 876) and the Pfeiffer's Short Portable Mental Status Questionnaire (n = 848). CI was defined as a Mini-Mental State Examination score <24 or Short Portable Mental Status Questionnaire (errors) >2. The independent association between permAF and CI was assessed by binary logistic regression analysis. A total of 295 patients (33.5%) had CI, in 5.1% of cases moderate/severe. Patients with permAF had more frequently any degree of CI (43% vs 31%), and moderate/severe CI (8% vs 5%). In the multivariate analysis, CI was associated with permAF (odds ratio 1.54, 95% C.I. 1.05 to 2.28), an older age, female gender, diabetes mellitus, chronic kidney disease, previous stroke, New York Heart Association class III/IV, and lower systolic blood pressure. No interaction was found for AF and CI between patients with reduced and preserved ejection fraction. In conclusion, the presence of permAF is independently associated with CI in patients with HF, both with reduced and preserved ejection fraction. Given the clinical impact of CI in the HF population, active assessment of cognitive function is particularly warranted in patients with HF with permAF.