The Equality Act applies to all service providers, and despite the fact that you can call it a public house, or whatever else, pubs are service providers. Shops fall into that category, even law firms.
As I mentioned, you can't discriminate on the grounds of a protected characteristic. It's an objective test for both whether you have discriminated, and whether it was justified. You still can discriminate, but you need to be sure you can justify it.
In the OP you mention prams; you can easily justify that in terms of space, and the fact that although you're limiting access to people with prams (potentially parents, a protected characteristic), it's justified on the basis that space is at a premium in a pub, staff have to get between tables and chairs with drinks etc. It'd be ok.
To bar, for example, anyone Indian, would of course be wrong, and as it should be, illegal.
Someone mentioned the guest house issue, and the couple not allowing gay couples to stay.
That was always going to be a difficult case, as you've two protected characteristics, religion and sexuality, effectively squaring up to each other. As a Court, do you risk upsetting the religious or the gay communities more? I'm glad I didn't have to decide that one, although I'd have favoured the gay community, not being religious (although I'm not gay either, but strongly in favour of gay rights).
You mention under 5's - age is a protected characteristic, but, as before, it would come down to justification.
Summary - you can discriminate against people, but make sure you have a very good reason if you plan to do it!