The England Under-21s winger started nine games last season and has been used from the bench in all four league outings so far in 2017-18.
Gray, whose current deal runs until 2020, has admitted to being frustrated by his lack of playing time in the East Midlands since joining from Birmingham City in January 2016.
Shakespeare told reporters on Thursday: "I am aware that [a deal] is closer. The sooner now that is put to bed the better for Demarai.
"We spoke before about Demarai being an integral part of what we are about, what we are trying to build and hopefully we can put that contract to bed."
Gray was said to be close to joining Bournemouth on transfer deadline day, only for the Foxes to pull the plug on a £25m deal.