Bayern have been struggling to reach an agreement with AZ Alkmaar but they have now managed to reach a compromise that will see Van Gaal leave the Dutch side.
“We understand that he will become our head coach on 1st July,” Bayern general manager Uli Hoeness said.
Bayern chairman Karl-Heinz Rummenigge added: “We are happy to have signed an experienced and successful football coach for Bayern Munich such as Louis van Gaal.”
Van Gaal has signed a two-year contract with Bayern Munich.