An inquisitive whale shark has given a group of fishermen a once-in-a-lifetime opportunity after it loitered around their boat for nearly five hours and allowed one of them to swim with it.

The fishing charter boat was anchored north of the Bonaparte Gulf, south-west of Darwin, when the shark, estimated to be more than five metres long, approached the boat.

Fishing guide Benny Sambrooks, who swam with the shark, said it was just "cruising around the back, wasn't moving too far at all".

"He was just coming up to the top of the water with his mouth open, cruising around, doing laps," he said.

Mr Sambrooks' clients were "pretty stoked to see it", but the novelty soon wore off, with the whale shark hanging around for four-and-a-half hours.

The encounter provided plenty of time for the fishermen to film the shark on their mobile phones.

They later sent the vision to the ABC's Tales from the Tinny program.

Once the clients went to bed, Mr Sambrooks jumped in to swim with the huge animal.

"There was a tiger shark there earlier in the day, so it was interesting," he said.

"But he was placid, [he] didn't budge."

Mr Sambrooks said the experience was "awesome".

"We always have a good experience, but we've never seen anything like that, you don't expect a whale shark," he said.

The biggest whale shark ever recorded was 12.65 metres, had a girth of 7 metres and weighed 25.5 tons, according to the Guinness Book of Animals and Feats, but there were also reports of sharks up to 18 metres long.

The sharks can have mouths up to 1.5 metres wide and 300 to 350 teeth, though these are tiny and the sharks are generally not aggressive towards humans.