Humpback whale
The 12m humpback whale that was rescued after being entangled in a fishing rope off Shelly Beach has died on a NSW mid-north coast beach - Representational Image Russell Boyce/Reuters

A 12m humpback whale that was entangled in fishing rope off Shelly Beach and rescued on Sunday (17 September) has died on a NSW mid-north coast beach. It had dragged the trap and ropes for more than 1,700km.

The NSW National Parks and Wildlife Service (NPWS) whale disentanglement team freed the whale but it struggled throughout the night to return to the sea from shallow waters.

The whale beached itself a few hours later and died on Nobby's Beach on Monday morning.

Beaches along the coast of Port Macquarie are closed due to the danger posed by the whale's carcass.

Neil Yates, unit commander at Port Macquarie Marine Rescue, said that the trap the whale was caught in was identified as coming from Tasmania.

"It looks like it's actually been tangled for possibly a year," he said.

"It doesn't look like it was a fresh entanglement and as such the condition of the animal was very poor.

"But the big message to get to people now is that the carcass is deteriorating.

"There will be some bits and pieces floating in the water which is going to attract large predators.

"Do not go in the water. I can assure you there are some very large sharks out there."

It is the annual southerly migration of humpbacks when the whales return from their warm water feeding grounds in southern Queensland to the Antarctic krill feeding grounds, Radio Australia reported.

In consultation with the NPWS and ORRCA, a decision to bury the 20-tonne animal in a deep hole on Nobbys Beach has been made, the Port Macquarie-Hastings Council said.