Shane Bieber and the birthday boy helped the Cleveland Indians end their skid.

Bieber took a shutout into the eighth inning, Jose Ramirez homered twice on his 28th birthday and the Indians beat the Detroit Tigers 10-3 on Thursday night. Cleveland snapped an eight-game losing streak.

The Indians entered the day holding the final American League playoff spot, and they had a four-game cushion despite their recent slide.

“Going into the postseason, it would be nice to get some momentum moving forward,” Bieber said. “A lot of good teams make it, but a lot of hot teams win it, so if we can get going towards the end of the season right now, I think we’ll be in a good spot.”

Bieber (8-1) didn’t allow a run until his final hitter, Willi Castro, hit a three-run homer in the eighth. That cost the Cleveland right-hander the major league ERA lead, but Bieber did become the first eight-game winner of this shortened season. He allowed four hits in 7 2/3 innings.

Bieber, a leading candidate for his first AL Cy Young Award, struck out 10 to raise his season total to 112, baseball’s top mark. He walked two.