The popular Northern Ireland golfer, currently world No 6, will be looking for his first victory in the prestigious European Tour event, having finished runner-up in 2009, 2011 and 2014.
McIlroy said: “I’ve finished second three times, so perhaps this is the year I can go one better and end my season on a real high.”
The four-time major champion has had a close relationship with the Alfred Dunhill Links over the years. In 2007, at 18, he became the youngest player to earn a European Tour card from tournament play when he finished third.
“The Alfred Dunhill Links is a great, late season event and I really enjoy the format. Played over three world-class courses I greatly respect, I can’t wait to come back again in October,” added McIlroy.
“The support I’ve had from the Scottish and visiting fans has always been fantastic and I have had some wonderful memories on these courses.
“I won my European Tour card after the 2007 Championship and I’ve played with my Dad a couple of times since – always very special experiences and times I’ll never forget.”
McIlroy heads a world-class field in the celebration of links golf, played over the Old Course St Andrews, Carnoustie and Kingsbarns, from 5-8 October.
Also confirmed is world No 16 Tommy Fleetwood, and a classic line-up of major winners, including Darren Clarke, Ernie Els, Padraig Harrington, Martin Kaymer, Paul Lawrie, Graeme McDowell and Danny Willett, plus current Ryder Cup captain Thomas Bjorn and vice-captain Robert Karlsson, who won the tournament in 2008.
Also in the field are former world No 1 Luke Donald, Ross Fisher, Matthew Fitzpatrick, Branden Grace, Chris Wood and Lee Westwood.
Defending champion Tyrrell Hatton returns to St Andrews attempting to become the first to win back-to-back Alfred Dunhill Links titles.