HowMuch.net compiled an infographic about the income you need to afford the average home in every US state. The key is that “afford” means that the total cost of housing take up no more than 30% of gross income. The highest income required is in Hawaii ($153,520 for a house worth $610,000) and the lowest is in West Virginia (West Virginia: $38,320 for a house worth $149,500).
I suppose the next level analysis would be to divide by the actual median income in each state to measure relative affordability. The same job can pay different salaries in different areas, so it can still make sense to move to a place with higher incomes and high real estate prices.