The 22-year old Repsol Honda rider broke the voluptuous Phillip Island circuit's lap record to pass Movistar Yamaha's Jorge Lorenzo on turn ten of the final lap.
Just behind, Ducati's Andrea Iannone snatched the last podium place from championship leader Valentino Rossi.
The race, in perfect conditions, was a vibrant showcase of MotoGP's appeal and its best riders' talents. Spectators were treated to pass after pass, with less than a second separating the first four at the flag. Iannone even recovered from hitting a seagull on the first lap, with the unfortunate bird slamming a hole in the fairing of the Italian's bike.
Marquez was clearly overjoyed at the win -- his first premier class victory in Australia. "It was a really fun race - certainly one to remember," he told reporters. "At the end I overtook Iannone and Valentino and I had a great last lap; I don't know where I pulled that time out from, but it was what made the difference for us!"
The result sees Rossi's lead over Lorenzo cut to just 11 points, entering the final two races of a memorable season. Two-time defending champion Marquez is 74 points adrift but can still influence the outcome of the championship as he did Sunday.
Lorenzo was disappointed not to take the win, but happy to claw back valuable points on his teammate.
"I think this was the most exciting race of the season and for sure one of the best in the last few years. To have four of the fastest riders fighting for victory in all the corners for the whole race is unbelievable," he said. "It could have been more but it also could have been less, but it's enough. At some point you have to be happy, look ahead to continue delivering this good work during the last two races."
Rossi meanwhile was left to rue his inability to hold off compatriot Iannone. The "Doctor" has a superb record in Australia, but struggled to exert his authority throughout the race weekend, qualifying on the third row.
"I had a good pace and good speed during the race, so arriving in fourth place is a pity, but it was still a good race," he told reporters. "We already said that race results was going to be important ten rounds ago, but now it's really important and it will be very tough until the last race."
Meanwhile, British fans' 38 year wait for a world champion continues, after Danny Kent crashed out of what could have been a conclusive Moto3 race. The Englishman was lucky to escape injury after a dramatic high side sent him flying off the track.
MotoGP now travels to Malaysia for next weekend, before returning to Europe for the final race on 8 November. The race for the top prize could scarcely be tighter.