It's partly due to r-conditioning of the vowels, but that merger is very common in English. Linguists call it the horse-hoarse or north-force merger. There's an article on wikipedia,
https://en.wikipedia.org/wiki/English-language_vowel_changes_before_historic_/r/#Horse%E2%80%93hoarse_merger