COSMOS gave thousands of older adults a cocoa flavanol capsule for years. The result that the trial was built to answer, and a later result that it was not built to answer, do not say the same thing. Neither result is a chocolate bar.
Short answer

Sesso and colleagues reported the cardiovascular paper in the American Journal of Clinical Nutrition (2022). Participants took cocoa extract with 500 mg of flavanols a day, or a placebo. The dose was a capsule from the trial pharmacy. It was not a square of chocolate, and the trial does not grade any brand of bar.
The primary outcome was total cardiovascular events (a composite the protocol named in advance). Those events were not significantly lower with the cocoa extract. If you only remember one line, remember that one. A trial is allowed one main question. COSMOS did not clear it.

Cardiovascular deaths were lower, by about 27%, in a secondary analysis. Secondary means the trial was not sized and locked to answer that question alone. A real difference can show up there. It can also be chance, or one slice of a bigger picture that did not move. The honest use of a secondary result is a hypothesis for a new study, not a claim that the capsule prevents death.
Baker and colleagues tested cognition in COSMOS-Mind (Alzheimer's & Dementia, 2023). Daily cocoa extract for three years had no effect on the global cognition score (mean z 0.03, confidence interval crossing zero). That is the cocoa result. It is not a reason to start any other supplement that happened to be in the same factorial design.

Halloween or not, the study object was a measured flavanol capsule. A bar of chocolate brings sugar, fat and a much less controlled dose. Liking chocolate is fine. It is not what COSMOS tested.

This post is general information, not medical or dietary advice.
Twenty-one thousand older adults took cocoa flavanols for three and a half years. Result?
They took five hundred milligrams of cocoa flavanols a day in a capsule. Not chocolate.
Total heart and blood vessel events weren't significantly lower. That was the main outcome. Heart deaths were twenty-seven percent lower, but that was a secondary result.
Secondary results only give ideas for new studies. And again: this was a capsule, not a chocolate bar.
The logbook stays on your device. You bring the chat AI you already use.
This blog does not give medical advice. Health disclaimer.