Ancelotti lead Real to their 10th elite European title last season but was sacked after the club finished runners-up to Barcelona in La Liga and lost to Juventus in the semi-finals of this year's Champions League.
“The deadline for a reply is Wednesday, June 3,” Galliani told journalists after meeting with the 55-year-old Italian at Madrid's Wellington Hotel.
“I'll make my decision on Wednesday,” Ancelotti confirmed, adding that he had “always gotten on well with Galliani”.
As for the “sabbatical year” that Ancelotti had said he was considering after his sacking, he added simply “we'll see”.
“Carlo wanted to take a year out, we're hoping to convince him to accept Milan,” said Galliani, whose side are tenth in the Serie A with one match left this season.
“He still has some days to think about it, he told me the chances were 50-50.”
The affable coach had said last weekend he would either stay at Real Madrid or take a year off to undergo surgery on a worsening and urgent health problem.
“I must have a back operation because of spinal stenosis that for some time creates a tingle in my hands,” he told Italian newspaper Il Giornale.
“I don't know how long the period of recovery will be,” he added. “But I can assure you that I've had plenty of (job) offers from Italy, England, Germany.”
Ancelotti coached AC Milan from 2001 to 2009, winning the Serie A in 2004 and two Champions League titles in 2003 and 2007, he also won the old European Cup twice as a player with AC Milan in 1989 and 1990.