Ordinarily, a baseball game consists of nine innings (in softball games and high school baseball games there are typically seven innings; in Little League, six innings), each of which is divided into halves: the visiting team bats first, after which the home team takes its turn at bat. However, if the score remains tied at the end of the regulation number of complete innings, the rules provide that "play shall continue until (1) the visiting team has scored more total runs than the home team at the end of a completed inning; or (2) the home team scores the winning run in an uncompleted inning."
The rules of the game, including the batting order, availability of substitute players and pitchers, etc., remain intact in extra innings. Managers must display caution to avoid using all their substitute players, in case the game reaches extensive extra innings. The rules call for a forfeiture if a team is unable to field a full team of nine players.
Home teams have won about 52% of extra-inning games in the last 50 years. During this same time period, home teams have won about 54% of all baseball games. So while the home team has some advantage in extra-inning games, this advantage is less noticeable than the initial home-field advantage. Home teams tend to have the greatest advantage in run-scoring during the first 3 innings.
For the visiting team to win, it must score as many runs as possible in the first (or "top") half of the inning and then prevent the home team from tying or taking the lead in the bottom half. Because it bats in the second (or "bottom") half of an inning, a home team wins the game by taking the lead at any point in the final inning. If the home team takes the lead in the final inning by virtue of a hit with one or more runners on base, the game will end when the first of those runners comes home and scores a run. No other subsequent runners will be allowed to come home and score, as the game will have already ended with the scoring of the first run. However, if the home team takes a lead in the final inning by virtue of a home run with one or more runners on base, each of those runners will be allowed to score and count in the final score of the game. Each extra inning simply repeats this scenario. A home run in such a situation is called a walk-off home run, and any win in this situation is known as a walk-off win.
Professional (minor league)
The record for the most innings ever played in a single professional game is 33 which occurred in a 1981 minor-league game between the Pawtucket Red Sox and the Rochester Red Wings, Triple-A affiliates of the Boston Red Sox and the Baltimore Orioles, respectively. Interestingly, each team had a future Hall of Famer on its roster: Wade Boggs for Pawtucket and Cal Ripken, Jr. for Rochester.
Major League Baseball
The longest game by innings in Major League Baseball was a 1-1 tie in the National League between the Boston Braves and the Brooklyn Dodgers in 26 innings, at Braves Field in Boston on May 1, 1920. It had become too dark to see the ball (fields did not have lights yet and the sun was setting), and the game was considered a draw. Played rapidly by modern standards, those 26 innings were completed in 3 hours and 50 minutes. As was the custom, the first pitch was thrown at 3:00 p.m.; home plate umpire Barry McCormick called the game as lights began appearing in the windows of buildings across the Charles River, just before 7:00 p.m.
The longest American League game, and tied for the longest major league game by innings which ended with one team winning, was a 7-6 victory by the Chicago White Sox over the Milwaukee Brewers in 25 innings, at Comiskey Park in Chicago in 1984. The game began at 7:30 p.m. on the evening of May 8, 1984, and after scoring early runs both teams scored twice in the 8th inning; but the game was suspended after 17 innings with the score tied 3-3 due to a league curfew rule prohibiting an inning from beginning after 12:59 a.m. The game was continued the following evening, May 9, 1984, and both teams scored three times in the 21st inning to make the score 6-6; finally, in the bottom of the 25th, the White Sox' Harold Baines hit a home run to end the contest. Tom Seaver was the winning pitcher in relief. A regularly scheduled game followed, meaning both nights saw 17 innings played; Seaver also started, and won, the second game. The official time of the entire 25-inning game was 8 hours, 6 minutes, also a major league record.
On September 11, 1974, the St. Louis Cardinals won a marathon night game against the New York Mets, after 7 hours 4 minutes, and 25 innings, also tied for the longest game to a decision in major league history. Two Mets' errors led to the Cardinals' winning run, starting with an errant pickoff throw that allowed Bake McBride to scamper all the way around from first. St. Louis won, 4–3. The Mets went to the plate 103 times, a record in a major league game; the Cards were not far behind with 99 plate appearances. All told, a record 175 official at-bats were recorded, with a major-league record 45 runners stranded. Only a thousand fans were still at Shea Stadium when the game ended at 3:13 a.m. ET. (Unlike the American League, the National League did not have a curfew.) This was the longest game played to a decision without a suspension.
On April 15, 1968, the Houston Astros defeated the Mets 1-0 in a 24-inning game at the Houston Astrodome. The 6-hour, 6-minute contest, which ended with the Astros' Bob Aspromonte hitting a grounder through the legs of Mets shortstop Al Weis in the bottom of the 24th, remains the longest shutout game in Major League history. It also had the most scoreless innings (23) in a major-league game.
The longest American League game to end in a tie was a 24-inning contest between the Detroit Tigers and Philadelphia Athletics on July 21, 1945. The teams were tied 1-1 when the game was called due to darkness at Shibe Park; the Tigers' Les Mueller had pitched a record 192⁄3 innings (and only given up one run) before being taken out in the 20th inning.
The longest game to end in a scoreless tie was a National League contest between the Cincinnati Reds and Brooklyn Dodgers on September 11, 1946. The teams went 19 innings before darkness fell at Brooklyn's Ebbets Field, forcing the game to be called on account of darkness. In the American League, the longest 0-0 game was played between the Washington Senators and Detroit Tigers on July 16, 1909. The game was called after 18 innings due to darkness at Bennett Park in Detroit. The longest scoreless period within a completed game came in the April 15, 1968 game between the Astros and Mets which remained scoreless after 23 innings.
The Washington Senators became the first team in Major League history to play multiple games of at least 20 innings in a season when they defeated the Minnesota Twins 9-7 on August 9, 1967, in 20 innings, having set a franchise record for innings played with a 22-inning win over the Chicago White Sox on June 12 of that year. This feat would later be accomplished by the 1971 Oakland Athletics who had games of 21 and 20 innings and the 1989 Los Angeles Dodgers who played two 22-inning games, against the Houston Astros in June and the Montreal Expos in August. 
The longest doubleheader in Major League history came on May 31, 1964. The San Francisco Giants beat the New York Mets 5-3 in nine innings in the day's first game at Shea Stadium, and then won the nightcap 8-6 after 23 innings (despite a rare triple play turned by the Mets in the 14th). The two games lasted a combined nine hours, 52 minutes. The Mets' Ed Kranepool played in all 32 innings of the two games; Kranepool had been called up to the team that day after having played in both games of a doubleheader the day before for their Triple-A farm club in Buffalo.
On June 8, 2013, the Toronto Blue Jays beat the Texas Rangers 4-3 in 18 innings while the Miami Marlins beat the New York Mets 2-1 in 20 innings. This was the second time in Major League history that two games of 18 innings or more were played on same day; the first was August 15, 2006.
On September 21, 2013, just past 2:00 a.m., the Tampa Bay Rays defeated the Baltimore Orioles 5-4 in 18 innings in a game that had started at 7:10 p.m. the night before. Both teams were in contention for an American League wild card slot, with Boston having won the AL East division while this game was being played.
On September 24, 2013, the Arizona Diamondbacks set a major league record by playing their 77th extra inning of the season when their game against the San Diego Padres at Petco Park went into the 11th inning. This broke the record of 76 extra innings played by the Minnesota Twins in 1969.
On August 10, 2014, at 12:39 AM, the Los Angeles Angels of Anaheim defeated the Boston Red Sox 5-4 in 19 innings in a game that had started at 6 PM the night before.  Albert Pujols' walk off homer was quickly reviewed, per Boston's request, but the call was confirmed. That same night the Toronto Blue Jays defeated the Detroit Tigers 6-5 in a 19 inning game of their own, Both teams used all their available bench reserves as well as their entire available bullpen, Toronto even used starting pitcher Marcus Stroman as a pinch runner at one point. Tigers starter Rick Porcello would be credited with the loss after coming into the game in the 18th inning. Toronto reliever Chad Jenkins would get the win after pitching 6 innings of relief (an unusually long outing for a reliever) With Jose Baustista hitting a walk-off single to score Munenori Kawasaki to win the game. Toronto starter R.A. Dickey had begun warming up in the bullpen in the top of the 19th and likely would have come on in relief had the game gone to 20 innings. The game was in the longest in franchise history for Toronto.
The longest major league postseason game was an 18-inning contest played between the Atlanta Braves and the Houston Astros on October 9, 2005. In the 4th game of a National League Division Series at Minute Maid Park in Houston, the Braves (who were trailing the series 2 games to 1 and facing elimination) took a 6-1 lead into the 8th inning. A grand slam by Lance Berkman in the bottom of the 8th brought the score to 6-5, and with two outs in the bottom of the 9th Brad Ausmus homered to tie the game and send it to extra innings. The score remained deadlocked at 6-6 until the 18th, when the Astros' Chris Burke (who entered the game in the 9th inning as a pinch runner) homered to left field to win the game and send Houston to the National League Championship Series against the St. Louis Cardinals. Roger Clemens, who was brought in to pinch-hit in the 15th and pitched the last three innings in relief, was credited as the winning pitcher in the 5-hour, 50-minute contest.
Exactly two weeks later on October 23, 2005, the same Houston Astros team lost to the Chicago White Sox in the longest World Series game by time, Game 3 of the 2005 Series played at Minute Maid Park which lasted 5 hours and 41 minutes. It also shared the record for the longest World Series game by innings at 14, tying Game 2 of the 1916 World Series played on October 9, 1916, between the Boston Red Sox and the Brooklyn Robins at Braves Field.
The 1991 World Series was the longest best-of-7 World Series ever in terms of total number of innings, running out to seven games, three of which were extra-innings contests (the longest of which ran out to 12 innings), a total of 69 innings before the trophy was finally claimed by the Minnesota Twins.
The 1986 National League Championship Series which also involved the Astros was notable for its two climactic extra-inning games. After the Astros and the New York Mets split the first four games of the series, the Mets won Game 5 in 12 innings and Game 6 in 16 innings to claim the pennant.
The longest major league All-Star Game by time was played on July 15, 2008 at Yankee Stadium, with the American League winning 4-3 in 15 innings after four hours, 50 minutes. The All-Star Game of July 11, 1967 at Anaheim Stadium also lasted 15 innings, but was considerably shorter in terms of elapsed time. The All-Star Game of July 9, 2002 at Miller Park was controversially declared a 7-7 tie after 11 innings, when both teams ran out of available pitchers.
The longest college baseball game was played between Texas and Boston College on May 30, 2009, in a regional NCAA Division I Baseball Championship tournament game at Austin, Texas. Texas won the game, 3-2, in 25 innings as the visiting team under NCAA tournament rules on home-team declaration during a tournament. The game lasted seven hours three minutes.
Nippon Professional Baseball
In the Japanese professional baseball leagues, as of 2011, games are limited to a maximum of 12 innings in the regular season and the playoffs, with an additional time limit of three and a half hours for games tied after the 9th inning in the regular season. Games that reach the limit are officially declared ties and are reflected as such in the team's record. In postseason play, the game will be replayed from the top of the first, 0-0, as an entirely new game, leading to seven game series that can go on for eight or even more games. On November 6, 2010, the record for longest Japan Series game was set in Game 6. The Chiba Lotte Marines and the Chunichi Dragons played 15 innings totaling 5 hours and 43 minutes. The game ended a 2-2 tie leading to a game 7 in which the Chiba Lotte Marines won the game and the championship.
The concept of extra innings does not exist in cricket: a match that ends with both sides all out with an identical number of runs is a tie. Due to the high-scoring nature of the game, tied matches are very uncommon, having occurred only twice in the history of Test cricket and rarely in other levels of the game. Much more common is a draw, which occurs if no result is obtained before the scheduled end of the match.
The World Baseball Softball Confederation (WBSC), created in 2013 as the new world governing body for both baseball and softball by the merger of the International Softball Federation (ISF) and International Baseball Federation (IBAF), inherited the extra innings rules of both predecessors.
In international softball, a special extra innings rule starts immediately after regulation. Each team begins extra innings with a player on second base (the last player to be put out). This increases the odds that teams will score and ensures a faster resolution. There is a drawback, though, in that the home team has a big advantage in going second. Should the visiting team fail to score, all the home team must do to win is, for example, get a successful bunt and sacrifice fly to score the winning run.
For international baseball, the 10th inning is played as normal, and the 11th inning begins with the game in a "reboot":
- The coach selects where in the batting order to start the inning.
- The batter immediately preceding the designated leadoff man is placed on first base, and the next preceding batter is placed on second base. The game proceeds as normal.
In subsequent innings, the batting order is not "rebooted", but the two players preceding the player scheduled to lead off the inning are placed on second and first.
The WBSC baseball rule has also been adopted by European leagues Division de Honor (Spain), Italian Baseball League, and Honkbal Hoofdklasse (Netherlands).
Since 2009, a modified form of the IBAF/WBSC rule has been in the rulebook for the World Baseball Classic. Unlike the standard rule, the batting order is never rebooted, and the first inning in which runners are placed on first and second bases is the 13th inning. However, this rule has yet to be actually used in a World Baseball Classic because no game in either the 2009 or 2013 edition lasted more than 11 innings.
Other methods include the following:
- Putting runners on second and third (those who made the last two outs of the past inning) and an 0-2 count on the batter with no outs, or
- Having bases loaded (runners being the last three outs of the past inning), with a 1-1 count on the batter and no outs.
- Baseball Explained by Phillip Mahony, McFarland Books, 2014. See www.baseballexplained.com
- Ask The Experts | BaseballLibrary.com
- St. Louis Cardinals (1892–Present)
- September 11, 1974 St. Louis Cardinals at New York Mets Play by Play and Box Score - Baseball-Reference.com
- Big Days in Astros History - April 15, 1968 - Astros win longest shutout ever played
- "Game Length Records". Baseball Almanac. August 10, 2014.
- Chisholm, Gregor (April 5, 2012). "Blue Jays top Tribe in MLB's longest Opening Day game". MLB.com.
- Townsend, Mark (June 9, 2013). "The Juice: Marathon Saturday includes 20-inning win for Marlins and 18-inning Blue Jays victory". Yahoo Sports.
- Brady, James (June 8, 2013). "Mets-Marlins, Rangers-Blue Jays both go 18-plus innings". SB Nation.
- "MLB Gameday: Diamondbacks vs. Padres". MLB.com. Sep 24, 2013.
- The longest World Series in terms of total number of innings was the 1919 World Series, which went to eight games in a best-of-9 format and included one 10-inning game, for a total of 73 innings.
- Hoch, Bryan (July 16, 2008). "Night is Young: AL walks off in 15th". MLB.com. Retrieved July 29, 2010.
- "Fit to be tied". CNNSI.com. July 9, 2002. Retrieved July 29, 2010.
- *Schlegel, John. "Texas wins NCAA record 25-inning game", MLB.com (MLB Advanced Media, L.P.), May 31, 2009.
- "2009 NCAA Div. I Baseball College World Series Bracket" (in column 1 (Regionals), click on Austin box; then click on Texas–BC box), NCAA.com (NCAA).