After Real Madrid signed defenders Eder Militao and Ferland Mendy, 21-year-old left-back Theo opted to make a €20 million (£17.9m/$22.3m) switch to Milan, bringing an end to his two-year spell with Los Blancos.
He also played three times for Real Madrid in the Champions League, helping the club to win the competition in 2017-18, and he told Milan's official website he hopes for more success in Europe with the Rossoneri.
"I'm really excited and happy to be joining AC Milan," he said. "I hope I can make history with this club.
"I'll give my very best for this club. AC Milan is a great club – that is why I have come here, to reach the very top and win the Champions League with the Rossoneri.
"I would like to tell you [the fans] that I'm here to make history and do my very best for you all.
"I'm delighted to be here. Forza Milan!"
Hernandez arrives as Milan's first signing of the summer transfer window, though midfielder Franck Kessie's two-year loan deal has also been made permanent.
More business is expected as new manager Marco Giampaolo gets his feet under the table following his move from Sampdoria.
His former midfielder Dennis Praet has been linked with a move to follow Giampaolo to Milan, though rumours linking Arsenal's Lucas Torreira with a transfer appear to have died down.
Whoever Milan to bring in, the new boss will have to hit the ground running. The decision to part company with club legend Gennaro Gattuso at the end of last season proved divisive among fans, despite missing out on Champions League football with a fifth-place finish.
While Hernandez' lofty ambitions are admirable, that underlines the scale of the task facing Milan if they want to return to their former place at the summit of European football - starting with closing the 22-point gap to perennial Serie A champions Juventus.