DETROIT — CC Sabathia looked like his old self for three innings and Domingo German was as good as ever in his new role.

We’ll see if that’s enough to help the Yankees down the stretch and into the playoffs.

After leaving his previous start with right knee pain following three effective innings, Sabathia again pitched well for three frames during a 6-4 win in the second game of Thursday’s doubleheader against the Tigers.

But he faltered in the fourth and didn’t get out of the inning.

He allowed just one hit through the first three innings before he gave up a walk and a single and was then chased by Brandon Dixon’s one-out, two-run double to left.

Sabathia said he was “excited and encouraged’’ by how his surgically repaired knee felt.

He ended up allowing two runs on three hits in 3 ¹/₃ innings while striking out five.

Sabathia threw 56 pitches before he was replaced by German in a strategy Aaron Boone said he could use during the postseason.

German was excellent in relief. He stranded Dixon at second and tossed four-plus scoreless innings in his second relief appearance of the season.

“He came in and didn’t skip a beat,’’ Boone said.

“I enjoy being a starter and the preparation between starts,” German said through an interpreter. “If I need to come into the middle of a game like that, I’m not gonna say no. I’m gonna be ready.’’

He also picked up his 18th win and added he’d like to get to 20.

“Of course,’’ German said. “Twenty is a big number. I never thought I’d get to 18 wins in my first full season as a starter.’’