Question is in the title. Just wondering if ancient beer was carbonated like today's beer? Egyptian beer? Medieval beer? Asian beer?
Carbonation in beer occurs naturally like champagne. Through fermentation the yeast digests the sugars and produces alcohol and Co2 the high amount of carbonation today is the result of completaly sealing the beer in the bottle when the fermation is almost complete enriching the beer with extra carbon. Without pressure the Co2 is free to escape in the atmospere. So the result can be from slightly carbonated to carbonated like today depending on how well the vessel for storage could hold pressure.
The production and consumption of beer in ancient times would have been considerably different than what we're used to in the developed world today. Instead of producing the beer and shipping it off to be sold, the vast majority of beer would have been produced and consumed very locally - as in family unit local.
When yeast completes fermentation, it leaves residual sugars that are (for them) indigestible. Spoilage organisms would have had trouble establishing a healthy colony during fermentation due to competition from the yeast, but after the yeast dropped from suspension, they would have no problem gaining a foothold to feed on the residual sugars and proteins. Before hops were added in or around the ninth century, or in areas in which hopped beer was not popular, it would spoil very rapidly after fermentation was complete.
They wouldn't have known the why for any of that, of course. They weren't even close to germ theory yet. But they certainly would have noticed when the beer got infected.
So it is likely that ancient beer was consumed toward the end of active fermentation, just as traditional Chicha is consumed today. This wouldn't have given the beer time to degas, so ...probably, yes. (I say "probably" not because it's my estimation, but because it's my understanding that we don't know for certain from a historical perspective.) However, after fermentation was complete, the beer would have rapidly degassed unless it were contained in an airtight vessel strong enough to withstand up to 2-5 atmospheres of pressure (for normal modern levels of carbonation).
After the widespread use of hops (which contains acids that inhibit bacterial growth) in beer, it is likely that beer was served flat more often, simply because it could be stored for longer periods of time, but we don't know for sure.
As others have pointed out, the strength of ancient containers is an important question. I don't know the answer; it's my follow-up question, too. I also wonder, however, about the economic and practical viability of procuring such vessels, even if they were up to the task of holding a couple of atmospheres of internal pressure.
I make wine and beer. This answer is probably general knowledge for most enthusiastic homebrewers.
Here is an overview for the likely existence of carbonation in beer in Europe:
As you likely know carbonation in beer is the result of co2 gas being released by fermenting yeast into the sugar-solution that they live in. If the container that the liquid is in is open-top the co2 will off-gas quite quickly after fermentation is completed. So if you want a fermented beverage and are not going to trap the gas then you need to drink it during the fermentation process. During much of European history most beer was made at home by a housewife and it would have been quite possible to make many small batches of beer and drink towards the end of fermentation if carbonation was wanted. We can really only speculate how often this happened because we have very little record of non-commercial brewing during the middle ages.
When one puts a carbonated beverage in a closed container you trap the gas as a solution in the liquid. Gas will try its best to escape the container and as many a home-brewer or sparkling cider/wine producer has discovered, the pressure from the gas can cause the container to explode. A strong barrel that is lined with resin and closed tightly will hold some carbonation. This is especially true if stored in a cool place. Due to these factors, its probable that beers produced commercially in cold areas could have some fermentation when first tapped would have some light carbonation but this would dissipate from the barrel fairly quickly as it was being served.
Eventually a tradition of "cask conditioning" developed with the advent of spiles. A spile is a piece of wood that allows co2 to escape a barrel so it doesn't explode during a secondary fermentation to produce carbonation. Its on my todo list to research when this practice began but so far the oldest example of spile use in beer Ive found is mid 19th century. Whenever it occurred, this new approach to cask conditioning would have likely been the genesis of widespread and consistent enjoyment of carbonated beer.