Manchester United were reported to be keen on James but Bayern have swooped in to secure his services until June 2019.
The Bundesliga club have confirmed that they have the option to purchase James outright once his loan deal ends.
German media outlet SportBild claim Real Madrid are being paid €10 million over the course of the loan and that Bayern will have an option - not an obligation - to buy James for €35.2m in 2019.
However, Marca is reporting that Bayern will be contractually obliged to pay the Spanish club €60m in 2019 to retain the former Monaco midfielder.
"We are very happy that we were able to secure this transfer. The commitment of James Rodriguez was the great wish of our coach, Carlo Ancelotti, after both had already successfully worked together in Madrid," said Bayern chairman Karl-Heinz Rummenigge.
"James is a versatile player. He is dangerous, creates many chances and has a great standard of shooting. With this transfer, we have been able to raise the quality of our team."
Real have been heavily linked with a move for Kylian Mbappe, of Monaco, this summer, and it remains to be seen if James' move will fund a further bid for the 18-year-old wonderkid.