The Netherlands international, 22, will cost 15m (£13m) euros with a further 2m (£1.7m) euros in add-ons.
"It's an incredible feeling to have joined," he said.
Malacia added: "This is a new chapter for me, a new league with new team-mates and a tremendous manager leading us.
"I know from playing against his teams in the Eredivisie, the qualities that he has and what he demands of his players.
"While I know that I am still young and will continue to develop, I can promise the United fans that I will leave everything on the pitch every time I pull on the red shirt."
The left-sided defender had been in talks with French club Lyon before United stepped in.
It had been hoped the deal for Malacia would be done on Monday but it was delayed waiting for a work permit.
John Murtough, United's football director, said: "Tyrell is an exciting, dynamic young footballer with excellent experience for his age, including five seasons in the Eredivisie, a European final and full International honours for the Netherlands.
"We look forward to seeing him continue to develop under the guidance of Erik ten Hag and his coaching team in the years ahead."