Most of us probably have an embarrassing anecdote about school and sex education. I still cringe a bit when I remember mine: in the middle of casting for the Nativity play, I innocently asked my primary school teacher, “Why is Mary called the Virgin Mary?” to the sniggers of my more worldly classmates. Safe to say I wasn’t cast as one of the Three Wise Men that year.

Cringeworthy as it may be when done badly, all children have the right to age-suitable sex and relationship education. It can teach children about appropriate and inappropriate adult behaviour in a world where some children will always – sadly – be vulnerable to sex abuse.

More than that, it can support children to learn what loving relationships look like, and to develop a healthy attitude towards sex.

Of course most children learn this at home with their parents, but many don’t – like those forced to witness physical and emotional domestic violence at home.

While sex and relationship education is part of the secondary curriculum, there is no requirement for academies – a third of all schools – and primary schools to teach it. The government last week said it would be maintaining the status quo , despite considerable pressure for them to change it. This is the latest decision by a government that sees the role of schools in equipping young people with emotional skills for life as far less important than teaching them academic subjects.

Compulsory sex education won’t stop abusers preying on children, but it might help them become more ready for the world

But sex and relationship education is even more important in a world where sex has increasingly taken on an online dimension. It’s hard enough to negotiate the intersection between relationships and the internet as an adult, let alone as a child.

Should you remain Facebook friends with someone you’ve been out with? (Unless you really don’t care whom they go on to date, the answer is always no.) What’s the etiquette for promoting yourself on an internet dating profile? (Believe me, by far the worst case of writer’s block I’ve ever had).

For children and young people, this world is of course much more confusing – and potentially dangerous. Yet many of them have easy access to it: lots of children have their own mobiles and tablets. A majority of teenagers have been asked for sexual images or videos online, while boys as young as those of primary-school age have watched online porn .

Of course we should do more to protect children and restrict their access to online material. But as a primary school governor, I know how naive it would be to believe you can wholly prevent children from seeing inappropriate content online, or that all children get to learn about positive relationships at home.

Compulsory sex and relationship education won’t stop abusers preying on children. It won’t stop pre-pubescent boys watching hardcore porn. But it might help children become more ready for the world: by helping them to keep themselves safe online, to be able to put inappropriate material in context, and to have a fair crack at understanding sex and relationships (to the extent that any of us do). That is surely no less important than being able to read and write.