The suspected shooter was himself a high school student, who was also believed to have shot dead the grandparents before heading to school.

According to the Bangkok Post, investigators searched the house of the suspect in Bang Bua Thong district and found the bodies of his grandfather and grandmother inside.

Both had fatal gunshot wounds to the head. With the grandparents’ deaths, the fatality count stands at nine, the newspaper reported.

Investigators believe that the suspect shot his grandparents dead and then went to school.

The exact timeline of the incident remains under investigation.

A student inside the school told the newspaper the gunman, dressed in a purple physical-education uniform, fired 26 rounds on the school grounds.

Another 34 rounds of ammunition were found at the scene, according to the Bangkok Post.

Investigators said 15 students were injured in the incident, and they were reportedly taken to hospital for treatment.

The suspect, who investigators have described as a student armed with a 9mm handgun, had barricaded himself on the third floor of the school's pink building. Police said he is beleived to have later died of self-inflicted wounds.

Thai Prime Minister Anutin Charnvirakul was quoted as saying by CNN: "I’ve sent relevant officials to the area. This is horrible, it shouldn’t have happened."

According to reports, gun ownership is relatively common in Thailand as compared to other South Asian countries.

There were more than 10.3 million civilian-owned firearms in Thailand, or around 15 guns for every 100 people, according to 2017 data from the Switzerland-based Small Arms Survey (SAS), reported CNN.

This year in February, a 17-year-old gunman stormed the a school in Hat Yai district, Songkhla province, and injured staff and pupils.

In one of the deadliest incidents in the history of the country in 2022, 36 people were killed, 24 of them children, in a massacre at a childcare center.