The Moroccan authorities have decided to survey all abandoned wells across the country after a trapped young boy died in a valiant but unsuccessful rescue attempt last week.
Rayan’s plight at the bottom of a narrow 32m (104ft) deep borehole gripped millions in Morocco and beyond.
A water ministry official, Abdelaziz Zerouali, said the survey was designed to prevent a repeat of the tragedy.
He said those who dug wells that flouted regulations would be required to pay to make them safe.
He added that more than 1,000 Moroccans a year were already being punished for illegal drilling.