Obviously the first thing to note here is that Civ4 beats both games in the soundtrack department

.
No, but seriously though, aside the ancient era where the music works mostly as an incentive to advance as soon as possible, Civ4's soundtrack is the only one in the series that I've felt really pulled off doing all the things that it was trying to do. That's mostly because it wasn't trying to do that much, though. There's a really nice title piece to bring across that we're going to be playing the history of the world and we're going to be having fun, and in-game it's just songs that fit each age, plus diplomatic ditties for each civ. The only really clever choice was the John Adams in the modern era - we haven't come up with a way to make Civilization's late game stop being boring and micromanagey, but at least the music expressed what needed to be expressed: Yes, you're repeating the same thing over and over again, but the events taking place as a result of your actions are grand and transformative.
I don't remember thinking much about Civ5's soundtrack. I played a bit of vanilla when it came out, didn't like it much, and haven't got into the expansions. Whatever it did, it at least wasn't particularly memorable to me.
CivBE's music doesn't quite manage to do everything that it tries to do. But, to be fair, it tries to do a
hell of a lot more than Civ4's music. Compare:
Civ4: Medieval era, you say? Well, how about a Latin chant? Here's twenty for a start, and I didn't even have to start digging into the Tallis. It all sounds appropriate for the period, none of it is too distracting or too boring, it goes on for hours upon hours, and it's really cheap to license too, so you're pretty much done.
CivBE: Okay, so you're landing on an alien planet? And it's a beautiful natural idyll, untouched by human hands, filled with strange and wonderful alien flora and fauna? And you've left behind an Earth that you miss dearly, but are looking forward to a brighter future here? And the new world also turns out to be a dangerous, ominous and unknown place? And it's one of three different kinds of biomes?
And yet somehow CivBE manages to pull its job off here just as well as Civ4, if not better. I'm not saying that someone who's never played the game would detect all of those themes in the music just listening to it, but there's a lot of ways that it could have been a bad match for the game and it was none of those.
And it keeps doing a good job well past landing, too. The world becomes more familiar, your civilization grows, little by little the planet becomes a place with humans in charge, and perhaps - the hope for victory for your ideals and your civilization comes closer. But at the same time, your threats become greater and more immediate, as the other civilizations work toward their agendas. And the music expresses all of this really damn well.
It's just that there are two places where the music falters, and one where it falls down. What's excusable is where the game tries to attach meaning to a special event with a musical cue - that's when you're launching a satellite or seeing a siege worm for the first couple of times. In my opinion, neither of those work. The abruptly switching music only takes you out of the game, if anything. But it's soon over, and the normal music picks up, and you forget about the distraction.
What's not so excusable is the finale pieces. You know, the ones that play when you've almost filled out a victory tracker. Don't get me wrong, not only are they amazing by themselves, they're also the payoff to all the work the other biome pieces have done to develop their themes. Hearing one for the first time was one of the best musical experiences I've
ever had in a game. It's just that, you know, I'd only just built the victory wonder. The whole business of playing the game for dozens of turns as I actually finished the victory condition was still ahead, and it was dozens of turns of very late-game CivBE, with dozens of cities and units and trade routes to manage. And meanwhile the music kept playing, with the amazing triumphant song as just another piece in the rotation. It was amazing the first time around, pretty good the second time around, but then it started falling flat. Really, really flat, over and over again.
If I hadn't played Civ4, I'm not sure I'd know that they could do better. How do you combine repetitively doing the same thing for dozens of minutes, if not hours, with the idea that you're about to fundamentally transform humanity and take the next step in our history as a species? It could be that the answer is that it takes a composer made of at least as stern stuff as John Adams.
But then, maybe this problem has a simpler solution. Maybe you could just make the logic for figuring out whether the player is "close" to a victory more restrictive - for instance, it's not enough to have built the victory wonder, you have to have less than X turns left on the transcendence counter, or have more than Y units sent to the Earth, or etc.. On the domination victory, the music could start playing when you have a unit at most Z tiles away from the last remaining player's capital. And so forth. That way the victorious music really would only play when victory really is (likely to be) close, not when there's definitely still plenty of late-game Civ to go. Or maybe there's some other solution.
Overall, though, if I actually had to give a trophy to one Civ game for its soundtrack, it'd be CivBE. Civ4 might have climbed its mountain, but CivBE shot for the stars and reached the Moon.