Paramedics airlifted the man from Britomart Reef to Townsville Hospital where he is being treated for critical wounds.
The man had been spearfishing near the reef before being attacked at about noon, media reported.
"There was obviously evidence of a very significant shark bite to the patient's upper thigh, pelvic region," said David Humphreys, a doctor with LifeFlight Australia.
"He remained in a critical condition after our interventions and he's now undergoing emergency surgery here in the hospital."
According to the Taronga Conservation Society Australia, there have been seven fatal unprovoked shark attacks in Australia this year, two of them in Queensland.
Australia ranked behind only the United States in the number of unprovoked shark encounters with humans in 2019, according to the University of Florida's International Shark Attack File.