With a few pretty minor exceptions, they're essentially random (or at least arbitrary).
The first one to be numbered was actually Earth-616. Alan Moore named it during a story about the Captain Britain Corps. The Corps was made up of Captain Britains from all the different realities, and (in-universe) they needed a way to identify each other.
The reason Moore picked a relative high number like 616 (at random) was two-fold:
- To get across the idea that this reality wasn't particularly special to the Marvel multiverse. (That's an idea that's been dialed back a bit -- 616 was the last reality to survive Secret Wars, for example).
- To avoid sounds like the DC multiverse, which had long-since established Earth-1, Earth-2, etc.
(There's a persistant rumor that Moore picked it because 616, in some interpretations, is the mark of the Beast in the Bible, but that story doesn't appear until much later, so I'm highly skeptical).
The bulk of these numbers are assigned by, I believe, one guy at Marvel who keeps a database. If you look at the entire current list you can see some smaller-scale patterns -- the What If comics are mostly clumped together, for example. Also, some specific Earths were assigned meaningful number: Earth-818793 is a Marvel Zombies crossover with the Evil Dead movies (it stars Ash); 81, 87, and 93 are the release years of the Evil Dead trilogy.
Beyond that, though, there's no particular "pattern" to them at all. Particularly with the "major" universes, they're all just assigned arbitrary (and relatively high) numbers.
My guess is that numbers for major universes, the ones people will use most often, are picked to be large and spread out, to reinforce the impression that Moore was going for: that the marvel multiverse is gigantic and that all of these different universes are just tiny parts of it.