Space is all the same temperature. Coincidence?

Distant patches of the universe should never have come into contact. So how come they’re all just as hot as each other?