It is the third new deal that the 22-year-old has signed in his 18 months with the Reds - a measure of the progress the club feel he has made since joining from non-League Bromley.
McCleary told the club's official website: "Coming from non-League and now having three years with a club with so much ambition is a dream come true.
"The club is looking to push on to the Premier League and I obviously want to be at the highest level of the game.
"It is fantastic. I am glad that the club have recognised certain things in me and I am delighted to be here."