Its a combination of things,
All motivated,largely academically inclined parents, You don't find any parents who care little for education at a private school, and all that goes with that at home, conversation, news, debate, etc.
State schools are not generally pushy, eg the guidance for state schools in the Pandemic as reported on here by teachers was to 'take care of the pupils well being' Lack of computers at many homes, took weeks or months, to get any lessons online, no follow up or marking in many cases. Of course some state schools did brilliantly just not all.
The message from my Dcs Independent schools was, 'under no circumstance let your grades slip, work just as hard from your home computer on teams'
Full school day 8.30 till 4pm no excuses, up and running in a week. Every set lesson marked, parents contacted for EVERY missed lesson. Total follow up as if in school. Assumed in the trenches, just make the best of it and crack on, attitude.
Of course that is just a couple of examples, but l have seen many similar having had Dcs in both.
Even small Independents have (imo) higher expectations and aspiration, of all their children. Much less mollycoddling, zilch woke attitude. Robust attitude to sorting out problems and standing on your own two feet.
Of course this is made possible by the absence of problem families, lack of commitment to education, smaller class sizes, etc.
There are good and bad Private and State schools and no one size fits all for children.
My DD is academic and flourishes in a strict,, no nonsense high achieving school with like minded pupils. Probably with excellent 'contacts' She loves her school.
My DS is flourishing in a non selective small gentle school which achieves good grades but has great pastoral care. Probably no future contacts. He loves his school.