The 21-year-old Spanish international has attracted interest across Europe after impressing for the Croatian champions in the UEFA Champions League this season.
Olmo learned his trade in Barcelona’s famed La Masia academy before joining Zagreb as a 16-year-old in 2014.
Barcelona were reportedly interested in bringing Olmo back to Spain as were the likes of Manchester United, Chelsea and AC Milan.
Olmo, who made his one and only Spain appearance last November, scored eight times for Zagreb this season.
Speaking to his new side's official website, he said: "Of course, I have noticed RB Leipzig's successful path in recent years.
"It is a young, attractive club that convinces me with its philosophy of developing talented players and placing their trust in them.
"I am now looking forward to getting to know the team as quickly as possible and to be on the pitch with the boys.
"I would like to contribute my strengths and help us to stay higher in the league and to be successful in all competitions for as long as possible."
Leipzig sporting director Markus Krösche added: “We are very pleased that despite many offers from other renowned clubs, we were able to convince Dani Olmo that we’re the right club for him to take the best possible next step.”
“He’s a fantastic player who’s technically very dangerous and has outstanding qualities in possession of the ball. He will give us more options in attacking areas and at 21 is far from the end of his development.”
Leipzig are four points clear at the top of the Bundesliga table.