BOSTON — If a season goes right — if a team clinches a playoff spot with some days to spare — a full-circle-like regression to spring training occurs.

A club sends out roughly half its positional starters for a few at-bats and pre-programs who will pitch that day pretty much regardless of score or situation. The pace is somewhere between serious and serene. The Yankees lived in this realm the final two days of the regular season, reviving March in late September by clinching home field for the wild card on Friday night.

But here is the thing: It didn’t all go right.

It never does. Not for any team. But good teams overcome, They navigate through the unavoidable DL stints and performance malfunctions to still be viable come October. The bad teams — are you listening Mets? — talk about if “we just would have stayed healthy” or “if (fill in the blank) just would have performed all year like he did in the second half.”

The Yankees persevered because of depth — in the majors and minors — and by relying on a culture of fortitude and honoring high expectations.

The Yankees have 20 of the 104 seasons in which a team reached 100 wins and No. 20 was accomplished despite:

— The catcher (Gary Sanchez) and first baseman (Greg Bird) having just about the most unhealthy/unproductive seasons imaginable.

— The projected third baseman (Brandon Drury) essentially introducing himself and then disappearing.

— The left fielder (Brett Gardner) having arguably his worst season.

— The best player (Aaron Judge) being lost for seven weeks, and the second- (Didi Gregorius) and third-best (Aaron Hicks) players each enduring a DL stint and then missing some more time at the end without the DL being necessary due to expanded rosters.

— Their ace (Luis Severino) turning into as bad a pitcher for the first six weeks of the second half as Neil Walker was a hitter in the first half.

— Jacoby Ellsbury never playing and the hoped-for replacement, Clint Frazier, hardly being available.

— Jordan Montgomery making six total starts.

— Aroldis Chapman, J.A. Happ, Gleyber Torres and Masahiro Tanaka being among those who went on the DL once while CC Sabathia landed on the list twice.

— Sonny Gray falling out of the rotation and Tommy Kahnle dropping out of the major leagues.

Aaron Boone had much to work through, including his own rookie season following a successful manager (Joe Girardi). There was the uneven 9-9 start, being swept four games at Fenway to pretty much assure the AL East was beyond reach and a lot of shaky late moments.

But when Sunday came and went, the Yankees were still alive, still in play for their 28th championship.

Luke Voit and Miguel AndujarAP

“This was never about one guy,” said Dellin Betances, whose shaky first four weeks of the season raised concerns he was not over his poor end to 2017. “There are a lot of pieces here, a lot of pieces that helped us win.”

The depth steeled the Yankees as reinforcements initially came from within, most notably Torres and Miguel Andujar, but also at key points Domingo German and Jonathan Loaisiga. And then the farm was still stocked enough and the front office motivated enough to use prospects to import Zach Britton, J.A. Happ, Lance Lynn, Andrew McCutchen and Luke Voit.

“It bleeds into the room the belief that the guys upstairs will get what you need,” bench coach Josh Bard said. “The guys in here are not blind. They see what management is willing to do.”

That actually was reinforced in the offseason, when the Yankees found a way to acquire the NL MVP, Giancarlo Stanton, and the largest contract in major league history, and shoehorn him into a payroll they vowed to keep beneath the $197 million luxury-tax threshold. It was a scream to the clubhouse and to the league that the surprise run to ALCS Game 7 last year was not enough.

That the Yankees are still alive for more and better this season — beginning with the wild-card game Wednesday against the A’s — speaks to an ability to trek through injury and underperformance. The ability to amend and rewrite the initial script. The skill and the will to persist through the muck that keeps two-thirds of the league out of the playoffs.

The season did not go as expected in most respects, except for this:

The Yankees are back in the playoffs.