Typically they're not measuring the frequency or phase itself, but rather the change in frequency or phase.
Edit: I should note that's only for analog circuits. DSP is also common.
This technique is known as superheterodyne, and Technology Connections has a wonderful video explaining it better than I can.
The simplest answer is that you use a narrowband bandpass filter around the transmitting station's center frequency to eliminate the signals from other radio stations, just as you do for AM radio, and then you measure the frequency of the remaining signal instead of its amplitude. This works because the frequency deviations are small compared to the spacing between the frequencies on which different stations are transmitting. Downconverting to an intermediate frequency by mixing with a local oscillator, as CodeBeater correctly said most FM receivers do, doesn't really alter this fundamental principle, although it does alter the details. (Most current AM radios are also superheterodyne designs.)
Most current FM radios use a phase-locked loop, as analog31 correctly said, which is sort of the same but sort of different; it gives better results. A PLL uses a much narrower bandpass filter which is centered on, not the nominal center frequency of the radio station, but the instantaneous, modulated frequency, which makes it much better at rejecting interference than the simpler approach. So the frequency band you're filtering down to gets swept back and forth in real time, thousands of times a second, to follow the FM signal.
There's the question of how your PLL can initially achieve its lock if its passband is so narrow, of course. I don't know how mainstream FM radio does this, but it's not as hard a problem as you might think; because broadcast FM radio's frequency is always oscillating back and forth around its nominal center frequency, you can just wait for the audio signal to cross zero. Alternatively, you can sweep the PLL's local oscillator frequency over the band until you achieve a lock.
I hope this is helpful!
https://en.wikipedia.org/wiki/FM_broadcasting#/media/File:RD...
Each radio station has 100khz of bandwidth centered on it's tuner frequency. in the, there are channel spacing rules that give some gaps +/- another 100khz of that. (That's why in the US, radio stations are typically on 'odd' decimals, ie 92.3 mhz, 94.1 mhz, etc) That chart does not show HD radio frequencies, which due to those spacing rules, and more accurate transmitters, are on the +/- 100khz spaces along side the original analog 100khz. You can "see" the audio modulating the frequency on the spectrogram. But the OFDM digital signal on either side looks like a band of more intense noise. It's mind blowing to realize there's a signal in that!
https://wiki.analog.com/university/courses/electronics/elect... has some of the analog approaches collected.
First of all, the pilot is only required for decoding stereo and RDS. Mono FM does not use a pilot, so obviously there had to be a way to detect FM before stereo came along. I linked to a few of the approaches in a sibling (cousin?) comment.
Second, the pilot is embedded in the decoded FM audio. You need to demodulate FM to get to it in the first place. If you look at the waterfall display in an SDR receiver, it might seem like the signal is already present in the original radio frequencies (especially during silent periods), but it's there only indirectly.
If you have silence in an FM transmission (say 96.6 MHz), the only audio component present is the 19 kHz pilot signal, which causes the FM radio signal frequency to vary between 96.6 MHz ± k*19 kHz (not sure what's the value for k, but it's not 1). The sine likes to spend most of the time near the extreme values of its range; plot a histogram of a sine wave and you'll see peaks on either end.
The waterfall is basically a histogram over frequencies so it gets those peaks as streaks on both sides of the main carrier frequency (plus smaller ones for other components in the signal).
Another fun one, when you have IQ samples, is the polar discriminator: calculate x[t] * x*[t-1] where x* is the complex conjugate, and take the angle with arctan. Feels a bit like magic ("is that all?") but is justified by the theory.
Many good AM receivers do exactly the same thing, especially those receivers which have "Synchronous Detectors" for AM.
It's just that the circuitry involved is simple for FM, but rather more complex for AM.
I've wondered if FM stereo drives pets nuts with its constant high-pitched tone.