In doing so, the Northern Irishman has ended a trophy drought that lasted just over a year since winning the DP World Tour Championship in Dubai last November.
The 24-year-old drained a 15-foot birdie putt on the 72nd hole after Scott had made bogey to clinch the title in dramatic fashion at Royal Sydney Golf Club.
This year's Masters champion, who was bidding for the Aussie 'Triple Crown' following victories in the Masters and PGA events, had led since posting a course-record 62 on Thursday.
He started the day four ahead of McIlroy, but could only post a one-under 71 to finish 17-under for the championship.
The Northern Irishman's superb six-under-par 66 means that Robert Allenby remains the only player to win the Australian Masters, PGA and Open titles all in the same season (2005).