What is the difference between a state school and a public school? In New Zealand there is only public schools, private schools and church schools.
In the UK some but not all private schools are called Public schools. This is because the oldest of them were founded at a time when the distinction to be made by people whose children received a formal education was between having your child educated at home by a governness or paying to have the child educated with others, i.e. a "public" education.
By the time properly public education was available, the naming convention had stuck. So a state school is a non fee-paying school to which anyone can send his/her children. Private schools are fee-paying and the older and more distinguished of these are called as well 'the Public schools'.