I've always heard that beer was the drink of choice of most people due to it being cleaner than water and that this practice was widespread across a large timeframe. Most famous example are probably the Egyptian labourers who drank up to five litres a day. My question is: if this practice of drinking beer was so common, did people switch to something else when the first Caliphate conquered them? Did they have a choice at all?
I've always heard that beer was the drink of choice of most people due to it being cleaner than water
I'm afraid that you're starting from a very widespread Popular Myth here, and I regret to inform you that it isn't true. I've made it my life's work to kill this myth, starting from this post; while it focuses specifically on Medieval Europe, the hydrology remains the same all over. Adding on to this, a user who no longer wishes to be tagged has a post re water sources in the MENA region.
With this in mind, we can answer the question quite simply with 'water'. However, I should note that what Islam says and what Muslims do are two related, but ultimately different, things. Let's put it like this: how many Christians are liars, adulterers, thieves, or do not love their neighbours as they love themselves? There is most definitely a Muslim drinking culture, though admittedly most of the answers I'm about to link cover the period after the first Caliphate.