A man, who was left stranded after his boat lost power and took on water, has been rescued in Moreton Bay, Australia thanks to his brave and faithful friend, Heidi the German Shepherd.

After a fisherman discovered the dog swimming in the bay and surrounded by boat debris, he raised the alarm to start an emergency search for the vessel.

A rescuer quickly saved Heidi and took her to Queensland Parks and Wildlife Service, where officials notified the Brisbane Water Police of the incident. The dog was transported to a vet for medical attention, but luckily she had no injuries even after treading water for a staggering 11 hours.

Meanwhile the Brisbane Water Police, Rescue 500, Volunteer Marine Rescue and Volunteer Marine Coast Guard mounted a rescue operation for the missing boat and its skipper, immediately deploying a helicopter, four boats and a jet ski.

Three hours later, the rescue group discovered a 63-year-old man desperately hanging onto his sinking vessel close to the Brisbane boat passage. After being in the water for almost 15 hours, the skipper was retrieved and transported to a local medical facility.

If the fisherman hadn’t spotted Heidi bravely battling the water, the outcome may have been much worse.

“Thankfully there was a happy ending to this search, said Senior Sergeant of the Brisbane Water Police Jay Bairstow, “and Heidi was able to be our honorary PD for the day.”

“We would take this opportunity to remind boaties to plan for the worst when they’re out on the water,” he advised. “Always wear a personal flotation device and ensure that your safety equipment, including EPIRBs, are tested and in good order.”