The Charlie Gard case has been a wake-up call for millions of people. Thanks to medical advances, we have grown accustomed to thinking that children are born healthy and all parents have to worry about is which school to choose for them. Clothes are bought in advance, nurseries painted and a Facebook page set up ready to go.

In reality, childbirth is still the most dangerous procedure that many women will go through in their lives, while the baby’s survival can never be a foregone conclusion. It was only 100 years ago that a couple would have around nine children and be pleased if four or five survived their first year.

Despite being a rabbi for 35 years, the only time I claim to have witnessed a miracle is when my wife was in labour and suddenly a child tumbled into the world, when a few seconds earlier it had not existed outside the womb. One moment there was two of us, and then we were three.

Charlie Gard judge says he will change his mind if evidence suggests he should

This combination of the always astonishing process of birth, plus the expectation that it will be successful, means that when something goes wrong, it is utterly shocking and we find it hard to know how to react.

This has become very apparent in the Charlie Gard case, and helps explain why it has not only captured the attention of the country at large, but divided opinion.

It is utterly right for parents to fight for every second of their child's life – but it is equally appropriate for them to know when to let go. It takes great sensitivity and willpower to see the child as a person in its own right and with its own needs, not as a possession belonging to the parents and subject to their priorities. Most parents would immediately deny they were pursuing the latter course, but their actions may sometimes speak differently.

This means making the truly difficult division between what is best for my child and what I want to be best for my child. It can involve great anguish when one realises that although one wants more time with one's dying child – not years or months, or even weeks – but just a few days, in fact it is better to say goodbye sooner rather than later, for the child's sake.

While such dilemmas may never be faced by most people – save vicariously through Charlie Gard – clergy are more familiar with them. Baby blessings and weddings may be more commonplace, but stillbirths and child deaths are a regular feature of congregational work.

What is noticeable is that virtually all parents feel that they are the only ones to have gone through such an experience, while many ask why God has singled them out. Explaining that life is full of risks, and that bad things happen simply because that is the way of the world, may be rational but is no help when it is your child lying lifeless in your arms.

Some families rail against God, or abuse the doctors, or blame each other; others quietly accept and instinctively sense what they need to do next.

I witnessed this when a young girl was involved in an accident. She appeared to be recovering afterwards but in fact was, unbeknown to everyone, suffering from internal bleeding.

She was put on life support by the doctors, but her body was closing down. The parents were told that the machine could keep her alive indefinitely, but she would never regain consciousness and would die the moment it was turned off.

Until shortly before then, they had expected that their daughter would live a normal life span – but they sensed immediately that now they had to let go. They each gave her one last hug, told her to head for the light, and gave the doctors the nod. I was there with them. We were all drenched in tears, but as we left the room, we knew it had been the right decision.

Of course, the same wrench can apply to a much-loved 90-year-old mother just as much. Letting go of anyone precious is always painful, and sometimes a little bit of us dies as well. But whatever the person's age, we need to have the emotional maturity to know when to do it for their sake.