correction

An earlier version of this story incorrectly reported that the Dodgers hit two singles in the top of the ninth inning before Camilo Doval threw a slider to lefty Cody Bellinger.

SAN FRANCISCO — Nothing sounds quite like a crowd stunned into silence by their villains somehow winning in the end, like the Los Angeles Dodgers did with a 2-1 victory at Oracle Park on Thursday night.

Nothing is quite as loud as the wave of quiet, then fury, that consumes a stadium as 40,000 hearts break in unison, knowing that for all the rooting and the hoping and the dozens of nights of brilliance, their team — in this case, their magical, inexplicable 2021 San Francisco Giants — is suddenly going home, on a questionable call no less.

That wave broke over Oracle Park in the bottom of the ninth inning of what will be remembered as one of the greatest games ever played in one of the greatest rivalries in baseball history, when first base umpire Gabe Morales punched out Giants first baseman Wilmer Flores on a check swing that looked, in retrospect, like he didn’t go around. After a season and series of endless back-and-forth, it was the only part of the night that did not fit, a sudden interruption of what was otherwise flawless baseball poetry.

“Super tough. Obviously, you don’t want a game to end that way,” Giants Manager Gabe Kapler said. “There’s no need to be angry about that. I just think it’s a disappointing way to end. There are other reasons we didn’t win today’s baseball game."

Said Morales: “Check swings are one of the hardest calls we have. I don’t have the benefit of multiple camera angles when I’m watching it live. When it happened live I thought he went, so that’s why I called it a swing.”

That Flores was batting in that situation against one of the best starters of his generation, Max Scherzer, was fitting somehow. The Dodgers traded for Scherzer for him to be the difference this time of year.

Dodgers Manager Dave Roberts said Scherzer had been lobbying for days to get a chance in this game. Eventually, he wore the Dodgers’ coaches down. Roberts pretended publicly that his Cy Young Award candidate wasn’t a viable option, even though he was a very good option all along. Scherzer said he knew going into the game that if he went to the bullpen he would probably pitch. And if he pitched, he would probably take the mound after Kenley Jansen, which is exactly what happened.

“Sometimes, a lot of times, you just have to trust the player,” said Roberts, who said he still expects Scherzer to start Game 1 of the National League Championship Series against the Atlanta Braves on Saturday.

That the Dodgers had a lead to hold in the ninth was itself the product of a wild and winding game that would probably have been better suited to Game 7 of the World Series than Game 5 of a division series, between two teams that won more than 105 games — the two best teams in baseball during the regular season, at least by the numbers.

The game effectively began Wednesday afternoon, when Roberts texted Kapler to tell him lefty Julio Urías wouldn’t be the Dodgers’ starting pitcher for Game 5 like they had announced. They would use reliever Corey Knebel as an opener instead. The Giants rely heavily on platoons, molding their lineups to the moment, and have all year. By starting a righty before going to Urías later in the game, the Dodgers felt they could limit the Giants’ ability to dictate matchups.

But after 23 evenly matched games, of which the Giants won 12 and the Dodgers 11, after years of familiarity between the front offices and managers, the Giants weren’t bothered. They figured a twist might be coming. After all the innings they had played, given all the ties between the organizations, even the surprise wasn’t all that surprising.

The Giants didn’t score against Knebel, nor the righty who followed him, Brusdar Graterol. By the time Urías entered the game in the third, the Dodgers hadn’t scored against Giants starter Logan Webb, either. Through five, none of the matchups both sides had so carefully crafted had yielded runs. All the maneuvering and managing hadn’t been able to separate the rivals, who at that point seemed as likely to spin into oblivion tied as to see one team come out ahead in the end.

In fact, the only clear matchup advantage for either side was Mookie Betts against Webb. By the sixth inning, Betts was 3 for 3 against the right-hander. The rest of the Dodgers’ lineup was hitless. Webb had given up eight hits in two NLDS starts to that point. Betts had five of them.

And while the Dodgers couldn’t turn his first four hits against Webb into runs, Betts seemed determined that the fifth would be different. He stole second to get himself into scoring position with one out. Corey Seager, last year’s NLCS and World Series MVP, doubled him home.

But after all that, after a year of chasing and being chased, one sixth-inning run was never going to be the end of it. The first Giant to hit in the bottom of the sixth, Darin Ruf, one of those right-handed hitters who might not have been in the lineup were Urías not looming, promptly hit a ball out to dead center field. The deadlock was restored. The madness continued.

The magnitude of the game in the context of such a rivalry was hard to overstate. Legendary broadcaster Vin Scully, who broadcast Dodgers-Giants games back when they still played them in New York, tweeted that Thursday night’s game was “the most important game in the history of their rivalry.”

The point was hard to argue given that in all those years of history and hostility, these teams had never met in the playoffs before — and given the fact that with 106 (Dodgers) and 107 (Giants) wins each, the winner of this series is also the likely National League pennant winner, if not the likely World Series winner, too.

Webb’s night ended with a swing and a miss and a roar to close the seventh. By that time, he had thrown 14⅔ innings in this series and allowed just one run, a legendary performance they will remember here for quite some time. Urías departed after the sixth, having thrown four strong innings. Who knows what might have been different had he started. By then, it didn’t seem to matter. The opener was an afterthought compared to who might be the game’s closer.

One candidate was rookie right-hander Camilo Doval, the hard-throwing, fearless reliever who burst onto the scene for San Francisco this season. With two out and two on in the top of the eighth, Kapler brought the 24-year-old in to face NL batting champion Trea Turner. Turner hit a high flyball to right field to end the inning.

The Dodgers turned to Jansen, their longtime closer, in the bottom of the eighth. He worked a scoreless inning. Doval came back out for the top of the ninth. He could not do the same. After a hit-by-pitch and a single, the hard-throwing Doval threw a slider to lefty Cody Bellinger, who has struggled with velocity all year. He hit it into right field to score a run, pointing to hitting coach Brant Brown in the dugout as he hurried to first because Brown had told his team to single the Giants to death in the ninth. Kapler had a matchup he liked. The Dodgers beat him.

“Players were in really good positions to succeed tonight, and they did in many ways,” Kapler said. “This is baseball. This is what happens.”

By that time, Scherzer was warming in the Dodgers’ bullpen. Roberts had suggested all week he didn’t intend to use Scherzer, but he said later he knew all along he had “an ace in the hole.”

“Just wanted to find the ultimate leverage spot to deploy him,” Roberts said.

He found it. Scherzer got the first out on a line drive to left. Then Justin Turner bobbled a groundball to put a man on first. Scherzer struck out Wade. Then came Flores, who Morales said didn’t check his swing in time.

“I didn’t think he went,” Kapler finally admitted, determined as he was to make clear that the season didn’t really come down to that one call.

Maybe Scherzer would have struck out Flores anyway. Maybe Flores would have gotten a hit to change it all. As it was, each team won 12 games against the other. Rivalries like this are never really settled. The history only adds decibels to the roars of the crowd to come.