For most of Monday night, the Red Sox and Marlins seemed determined to see which team could squander more scoring opportunities.

Miami put runners on base all night, while Boston repeatedly failed to cash in on its own opportunities. Somehow, though, the Red Sox hung around long enough to do what they’ve been doing a lot lately: come from behind and win.

The Red Sox went just 1-for-14 with runners in scoring position and stranded 10, but the Marlins were even more wasteful, going 2-for-18 and leaving 14 aboard.

With the game tied entering the ninth, Mickey Gasper worked a leadoff walk against Pete Fairbanks, who then exited with an injury. Eli White entered as a pinch-runner, and Seigler greeted Tyler Zuber by ripping a triple down the right-field line to bring White all the way around from first.

Seigler hadn’t started in eight days, but the Sox’ “spark plug” delivered in when his team needed him the most.

“I don’t know if you would call that speeding around the bags, I’m just glad this field is huge,” Seigler joked to NESN’s Jahmai Webster. “Great at-bat by Mickey to get it going and then I was just trying to get a good pitch to hit and keep the line rolling.”

Nick Sogard followed with an RBI single to provide some insurance before Aroldis Chapman closed it out for his 30th save. Chapman has now reached 30 saves in a season 10 times and sits at 397 for his career, three shy of becoming the ninth pitcher in MLB history to reach 400.

The late breakthrough came after Boston spent much of the night failing to take advantage of its chances against Sandy Alcantara.

Jarren Duran and Gasper opened the third with consecutive singles, and Seigler’s groundout put two runners in scoring position with one out. Alcantara escaped by striking out Sogard and getting Ceddanne Rafaela looking.

Rafaela unsuccessfully challenged the called third strike, dropping him to 6-for-24 on ABS challenges this season.

Gasper finally broke through against Alcantara with an RBI double that tied the game 1-1. It continued a torrid stretch since his Aug. 16 recall from Triple-A Worcester. Gasper is 8-for-19 with three homers, three doubles, 10 RBI, and four walks while striking out only once.

Boston threatened again in the seventh when Duran hustled a routine single into a double before Alcantara walked Gasper and Seigler to load the bases with one out. Once again, the Sox came away empty after Sogard struck out and Rafaela flew out.

Miami immediately made the Red Sox pay, taking the lead in the bottom half of the inning.

Brayan Bello, who worked a clean sixth after replacing Ranger Suarez, ran into trouble in the seventh. Otto Lopez led off with a double and two walks loaded the bases before Xavier Edwards punched a single through the right side to put Miami ahead, 2-1.

Willson Contreras kept the inning from unraveling. With the bases still loaded, he knocked down Jakob Marsee’s liner at first, recovered the ball in foul territory and fired home for the force, keeping Boston within a run.

Boston answered in the eighth inning when Wilyer Abreu doubled to open the inning, advanced to third and scored on Josh Ekness’ wild pitch to tie the game at 2-2.