Health
The honest answer is: not any more, not by itself — and if you have been hunting through your health app for the button, it is not you. The phone makers offered this once, and both of the big ones have taken it away. Here is what happened, phone by phone, and what actually works now.
Older Galaxy phones — the Galaxy S5 through the Galaxy S10 (2019) — had a real heart-rate sensor on the back, beside the camera, and Samsung Health measured your pulse with a fingertip on it. Samsung stopped putting that sensor in after the S10. On any newer Galaxy, Samsung Health cannot measure your heart rate on its own; it can only show readings that arrive from a Galaxy Watch.
For a while, the Google Fit app on Pixel phones could estimate your heart rate from the camera, with your fingertip held over the lens — Google itself labelled it an experiment that “may be removed.” Google is now closing the Fit app down and moving everyone to its Google Health app (the renamed Fitbit app), and the camera measuring did not move with it. The new app reads heart rate from a Fitbit or a Pixel Watch, not from the phone.
Apple has never put heart-rate measuring in the iPhone itself. On an iPhone, heart rate has always come from an Apple Watch.
They exist, and they work the camera way — fingertip over the lens, hold still. Treat one as a rough idea only: lighting, movement, and cold fingers all move the number, and none of them is a medical instrument. If a reading from one ever frightens you, do not let the app have the last word — that is a question for a person, not a program.