What hreflang does
Hreflang annotates a set of pages as language and region equivalents of one another. When a Spanish-speaking user in Mexico searches a query that matches your content, Google can choose your Mexican-Spanish page over your Spanish-from-Spain page even though both pages cover the same topic. Without hreflang, Google guesses based on TLD, server location, and content language signals — and often guesses wrong.