A diver has been caught inside a whale's mouth before being spat out alive off the coast of South Africa. Rainer Schimpf had been filming a sardine run - where gannets, penguins, seals, dolphins, whales and sharks gather fish into bait balls. As he was snorkelling on the surface of the water off South Africa's Port Elizabeth Harbour, a Bryde's whale emerged and its open jaws, engulfing him headfirst. He said: 'Once I felt something had grabbed me on the hip, I knew instantly it was a whale and my next thought was that, firstly, he can't swallow me because I'm too big - so that was kind of an instant relief. 'Obviously he realised I was not what he wanted to eat so he spat me out again.'

A diver was swimming off the coast of South Africa to photograph sharks when “everything went dark” and he quickly realised a whale had swallowed him whole.

South African photographer and dive tour operator Rainer Schimpf, 51, was off the coast at Port Elizabeth when he looked down and realised a mammoth Bryde’s whale was getting a little too close for comfort.

The sea around him started to churn into a dark mess, and he quickly found himself inside the whale.

“Nothing can actually prepare you for the event when you end up inside the whale and then its pure instinct,” Mr Schimpf said.

Mr Schimpf has been working as a dive tour operator in the town for more than 15 years and documents the sardine run every year.

The diver was trying to get a photo of a shark going through a bait ball when it “all happened very fast”.

“It got dark, I felt some pressure on my hip, and I instantly knew a whale had grabbed me,” he said.

“I could not imagine how the whale had grabbed me or was holding me, but I instantly knew it had grabbed me because of the pressure on my hip.

“There is no time for fear in a situation like that, you have to use your instinct.”

Mr Schimpf instantly held his breath, fearing the whale was going to dive down with him and spit him out deep below the surface.

Bryde’s whales can weigh up to 20 tonnes and other dive tour operators, who witnessed the terrifying event, admitted even getting bumped by one of the mammal’s flippers could easily break ribs.

“The next moment I felt the whale was turning either way, and the pressure was released, and I was washed out of the mouth,” Mr Schimpf said.

“I came back up onto the surface where surely I wasn’t looking too clever.”

The 51-year-old’s fellow dive teachers said his incident with the whale was undoubtably an accident.

“As they come up with their mouths open, they can’t see what is in front of them, and I guess the whale thought it was a dolphin,” diver Claudia Weber-Gebert said.

“Whales are not man-eaters. This was no attack, it was not the fault of the whale, and they are really sensitive. They are gentle giants, and it was just an accident.”

The video of the dive has gone viral, garnering more than 1.5 million views on social media in a couple of days.

“Had it been a shark it would have been two of me, and I don’t think that I would have seen anything again,” Mr Schimpf later told 9News.

“It is quite the tale to tell ... I was spat out by a whale.”

Bryde’s whales can dive for up to 20 minutes on one breath and are capable of reaching depths of up to 300m.

They typically grow to more than 15m in length and feed on a variety of fish and plankton.