IQ tests measure certain cognitive abilities, but comparing extremely high scores can be complicated. Different assessments use different scales, and some famous scores are historical estimates rather than results from comparable standardized tests.

I found this overview useful as an introduction to the subject:
https://thecampusreview.com/stem/highest-iq-in-the-world/How should historical IQ claims be evaluated, and what limitations should readers keep in mind when comparing scores?