Wrap a soft tape around your head 1" above your ears and eyebrows — where the hat will actually sit.
Standard hat sizes (head circumference): 21" = S, 22" = M, 23" = L, 24" = XL.
Numeric hat sizes (US): 6 7/8 = 21.6", 7 = 22", 7 1/8 = 22.4", 7 1/4 = 22.8", 7 3/8 = 23.2".
EU sizes: 54cm = US 6 3/4, 56cm = 7, 58cm = 7 1/4, 60cm = 7 1/2.
Stretchy or adjustable hats give more leeway. Fitted caps (New Era 59FIFTY) need exact sizing.