Elon Musk called British diver Vernon Unsworth a "pedo guy" in a thread of Twitter attacks on Sunday.

Earlier, Unsworth, who helped rescue 12 boys and their soccer coach from a Thai cave, criticized Musk for creating a "PR stunt."

Musk deleted his tweets without explanation hours later on Sunday.

Elon Musk called a diver who helped in the Thai cave rescue a "pedo guy" in a lengthy, baseless Twitter thread on Sunday that he later deleted.

Musk was responding to criticism from British caver Vernon Unsworth, who told CNN that Musk "can stick his submarine where it hurts."

Unsworth, who lives in Thailand and has spent years exploring the Tham Luang cave system where the boys were trapped, was a key player in the dramatic rescue of the 12 boys and their soccer coach.

Musk created a "kid-size submarine" and went to Thailand to assist in the rescue, but authorities ended up not needing his device.

Unsworth called Musk's creation a "PR stunt" and said the submarine would have failed to make it 50 meters into the cave.

"It just had absolutely no chance of working. He had no conception of what the cave passage was like," Unsworth said.

In his first tweet of the thread, Musk said he didn't meet Unsworth and that he "never saw this British expat guy who lives in Thailand."

In the same thread, Musk also responded to Unsworth's claim that the Tesla CEO was asked to leave the cave and his help was not appreciated by officials leading the rescue mission. "Thai navy seals escorted us in — total opposite of wanting us to leave," Musk wrote.

Musk has since deleted these tweets. Elon Musk/Twitter

Believing the sub he built would have been able to get the trapped children out of the cage, Musk wrote, "I challenge this dude to show final rescue video."

In his next tweet six minutes later, Musk replied, "don't bother showing the video" and promised to send his sub to the spot where the soccer team was trapped.

"I was *asked* to help repeatedly," Musk continued in another tweet. "Declined several times, as I thought they had it in hand & only agreed to help when Thai SEAL died (deep cave pumps not operating at time). We designed the mini-sub to Stanton’s specifications *and* brought a flexible rescue pod just in case."

Musk draws ire for tweets

Musk was widely mocked on social media after the boys were rescued without the use of his submarine. He hit back at his critics this week, saying the dive team had instructed him to keep working on the submarine.

Musk has since deleted these tweets. Elon Musk/Twitter

In other replies to critics on Twitter Sunday morning, Musk said, "Stay tuned jack--- …" and "Bet ya a signed dollar it’s true" to someone expressing skepticism that Unsworth could be a pedophile.

Musk deleted the Twitter thread hours later on Sunday, but not before they had been captured in screenshots.

The tweets came just two days after a Bloomberg interview where Musk said he was trying to stop attacking people on Twitter.