To shorten a fairly long and not super interesting story: it was arbitrarily chosen by a powerful team owner back around 1905 when he came up with rules for the series. He was considering five, but decided seven would be better for pitchers (since one bad game would not be as devastating). He also thought seven was a lucky number.
The league experimented with playing some nine game series in 1919-1921, but felt nine was too long, too expensive, and increased the risk of the last games being interrupted by poor late-autumn weather.
The 2009 World Series was a 6-game series. No game 7.
There was no game 7 in either the 1907 World Series nor the 2007 Series.
1952 World Series - 1952 Game 7 was released on: USA: 7 October 1952
2011 World Series - 2011 Game 7 1-7 was released on: USA: 28 October 2011
1971 World Series - 1971 Game 7 1-7 was released on: USA: 17 October 1971
1973 World Series - 1973 Game 7 1-7 was released on: USA: 21 October 1973
1958 World Series - 1958 Game 7 was released on: USA: 9 October 1958
1982 World Series - 1982 Game 7 was released on: USA:20 October 1982
1965 World Series - 1965 Game 7 was released on: USA: 14 October 1965
1972 World Series - 1972 Game 7 was released on: USA: 22 October 1972
1962 World Series - 1962 Game 7 was released on: USA: 16 October 1962
Randy Johnson was the winning pitcher for game 7 of the 2001 World Series.