The importance of adequate nutrition on cognitive performance is well recognised. Greater intakes of soft drinks are associated with a higher risk for type 2 diabetes, as well as other cardiometabolic diseases. A few studies have specifically examined whether the intake of soft drinks may be related to cognitive function. The aim of this study was to investigate whether soft drink intakes, including both sugar-sweetened and diet beverages, are associated with cognitive function, with adjustment for cardiovascular, lifestyle and dietary factors, and stratified according to type 2 diabetes status. Cross-sectional analyses were undertaken using 803 community-dwelling participants, aged 23–98 years, from the Maine–Syracuse Longitudinal Study. Cognitive function was measured using an extensive battery of neuropsychological tests. Usual dietary intake of soft drinks was assessed using a FFQ. Stratification by type 2 diabetes indicated that a greater intake of sugar-sweetened soft drinks was significantly associated with poorer performance in visual spatial memory, working memory, scanning and tracking, executive function, the global composite and the Mini-Mental State Examination in diabetic individuals. These relations were not attenuated with statistical control for BMI and other cardiovascular, lifestyle and dietary factors. Diet soft drink intake was unrelated to cognitive performance. Frequent sugar-sweetened soft drink intake was associated with poorer cognitive performance, particularly in individuals with type 2 diabetes, but the underlying causal mechanisms are yet to be determined. Longitudinal studies are needed to clarify these findings and the underlying causal mechanisms.