We are using HT20 on 2.4 GHz and HT40 on 5 GHz
The limit is a soft limit which works pretty well but every once in a while I check our controller and I see one of our APs has 23-27 devices connected and when I see that I just make a few of the least active clients reconnect to our network so they choose a different AP.
With iPads at least, the advertised feature of 25-30 clients connected to a single Unifi AP is EXTREMELY exaggerated. When we see ~25 clients connected to one of our APs is often when things go sideways in that classroom.