Buddhist males in Thailand are traditionally expected to enter the monkhood, often as novices, at some point in their lives to show gratitude, often toward their parents for raising them. It's believed that once a person is ordained they gain merit that is also extended to their parents.

The boys' heads were shaved in preparation. Pictures: AP (AAP)

In this case the boys were dedicating the act of entering the monkhood to a volunteer diver and former Thai navy SEAL, Saman Gunan, according to Praphun Khomjoi, chief of the regional branch of the National Office of Buddhism.

Mr Gunan died while diving during a mission to supply the cave with oxygen tanks essential to helping the boys' rescue.

"The teachings that we would like to the boys to learn is the awareness of themselves and the importance of their lives," Mr Praphun said.

"It is extraordinary to be born as humans. And as we are given this opportunity, we should use Buddhist principles or principles of any religions as guidance for living.