Study objectivesPrimary insomnia (PI) triggers a decline in cognitive function, and the thalamus plays an integral role in this process; however, the mechanisms are unclear. The purpose of this study was to investigate the altered functional connectivity (FC) of the thalamus in PI patients with mild cognitive impairment (MCI) and to explore the potential neural mechanisms of thalamic involvement in these patients.MethodsThis case–control study was conducted in older adults from various communities in Fuzhou, China with a PI diagnosis. These participants underwent neuropsychological assessment and were matched in a 1:2 ratio to the healthy control (HC) group and the PI group according to sex, age, and education level. Resting‐state functional magnetic resonance imaging was used to explore changes in thalamic FC in PI patients. To further compare changes in thalamic and whole‐brain FC, we further divided the PI group into cognitively normal patients and patients with MCI according to the diagnostic criteria for MCI. The relationship between abnormal FC and cognitive function was investigated.ResultsThe 28 HCs and 58 participants with PI showed significant differences in Montreal Cognitive Assessment (MoCA) scores (p = .044). In comparison to the HC group, the PI group showed enhanced FC of the occipital thalamus with the left inferior occipital gyrus, right lingual gyrus, left middle temporal gyrus, left superior marginal gyrus, left dorsolateral superior frontal gyrus, and right anterior central gyrus. The MoCA total score and the executive function, attention, and abstraction scores of PI patients with MCI (PI–MCI) were worse than those of PI patients without MCI. In comparison to the simple PI group, FC was enhanced in the PI–MCI group between the left occipital thalamus and the middle occipital gyrus, and between the right occipital thalamus and the right superior frontal gyrus, left middle frontal gyrus, right superior occipital gyrus, and orbital inferior frontal gyrus. There was a significant negative correlation between the MoCA total score and the enhanced FC between the right occipital thalamus and right superior occipital gyrus (r = −.419, p = .042).ConclusionThe early onset of cognitive impairment in patients with PI is associated with altered FC between the thalamus and the cortex. Enhanced FC between the thalamus and the visual cortex, that is, the superior occipital gyrus, which is involved in attentional processing, may play a role in the early onset of cognitive impairment in insomnia patients. Moreover, due to the fact that PI patients “overdraw” the compensatory capacity of these brain regions earlier, the PI–MCI may fall into the abyss of “decompensation” faster and face more severe cognitive impairments.