Where does the phrase “to warm the cockles of one’s heart” come from and What does it mean?

The phrase “to warm the cockles of one’s heart” means: To evoke a glow of pleasure in one; to produce a feeling of friendliness, affection, sympathy, or the like in one.

Considering the fact that the study of anatomy, most other studies too, for that matter, was stagnant throughout the Dark Ages, or roughly from the time of Galen in the second century to that of Vesalius in the sixteenth, it is astonishing that anatomists of the seventeenth century were already likening the human heart to the shape and valves of the mollusk, common on European shores, and the cockle.

That is to say, they saw sufficient resemblance between the two valves of the mollusk and the two ventricles of the heart to refer to the latter as the cockles.

Thus, because the heart was long supposed to be the seat of the affections, men spoke of delighting, of rejoicing, of pleasing, and, more recently, of warming the cockles of one’s heart.