Generally about 8. I found mine were more confident to go into the men's around then. They had the benefit of being a pair of brothers so could go together, but DS1 is autistic affecting his social confidence and would have struggled more without a same-sex sibling.
We found swimming more awkward. DS1 is dyspraxic too, so he wasn't ready to change alone in a unisex cubicle or communal male by the time he had to stop using the communal female changing.
For a year or so we used the disabled changing as logistically we could only use the two family size cubicles and with 40 children coming out of lessons at the same time, he was regularly getting frozen waiting for prolonged periods because we couldn't get in to them or practically use the communal female, male or individual provision. When he was able to change independently, we stopped using the disabled and he started using the individual cubicles.
One time, I had to go in to the men's toilets at a campsite (fortunately only occupied by a female cleaner, I did check!) because DS2 then aged 6 had a surprise poo and was struggling to manage by himself.
5 is unquestionably (by sane people at least) plenty young enough to go in with the sex of their parent. 5 year olds can still need some occasional help anyway.
With autism and continence issues in the mix, using the disabled facilities is a reasonable option and may work better in some circumstances. That might be a temporary, case-by-case or long term option to consider.