Van Marwijk stepped down after the Oranje lost all three group games at Euro 2012 last month.
The 60-year-old Van Gaal, sacked by Bayern Munich in 2011, will take charge of Netherlands for the second time having previously been coach from 2000-02.
The KNVB said in a statement that the 60-year-old had signed a two-year deal.
"I'm glad the KNVB approached me, this is the challenge I have been waiting for," said Van Gaal.
He will be joined by assistant Danny Blind, the former captain of Ajax Amsterdam.
"We were looking for a coach with experience, personality and professional skills," said KNVB director Bert van Oostveen.
"Van Gaal has earned his credentials nationally and internationally and we know him as a dedicated coach."
The veteran coach resigned from the post after the Dutch failed to qualify for the 2002 World Cup, the only major tournament finals they have missed since 1988.
Van Gaal began his coaching career in 1991 at Ajax where he won three league titles and the Dutch Cup.
He also lifted the UEFA Cup in 1992, the Champions League in 1995 and reached that final again a year later.
After his time at Ajax, Van Gaal enjoyed a spell with Barcelona before taking over his national side.
He won the Dutch league with AZ Alkmaar in 2009 and then joined Bayern where he won the double in his first season and reached the Champions League final.
Van Marwijk produced the best run of a Netherlands coach when he won his first 14 competitive matches in charge and led the side to the 2010 World Cup final where they lost to Spain.
He decided to leave when the Dutch lost to Denmark, Germany and Portugal at Euro 2012 in Poland and Ukraine.
Van Gaal's first match will be a friendly on August 15 against Belgium.
The Dutch start their World Cup qualifying campaign at home to Turkey on September 7.
- Sports & Recreation