Alexander Zverev started his grass-court season by dropping the opening set to German compatriot Oscar Otte before steadying to win 6-7 (5/7), 6-3, 6-4, at Halle on Tuesday.
Earlier, Italian Jannik Sinner, in his first match as world number one, also lost a first-set tiebreak but fought back as he beat Tallon Griekspoor 6-7 (8/10), 6-3, 6-2.
Second-seed Zverev, who has twice lost the final of the Wimbledon warm-up event, stayed calm and outlasted qualifier Otte.
"A week ago, I was playing on clay," Zverev said in his on-court interview. "He made it very tough for me, no rhythm at all. That's how grass-court tennis is sometimes.
"I'm obviously happy that I won and hopefully it's going to be a level above in the next match," said Zverev, who was playing his first match since losing the French Open final to Carlos Alcaraz on June 9.
Sinner, 22, who moved to the summit of the rankings with a semi-final finish at this year's Roland Garros, was made to work early on by Dutchman Griekspoor.
Griekspoor, 27th in the rankings, won the first set in a tie break.
Australian Open champion Sinner recovered to claim victory, two weeks out from the start of Wimbledon.
"It was for sure mentally tough," Sinner said in his on-court interview. "I was 5/1 up in the tie-break in the first set. But this can happen, especially on this surface, it can go very, very fast.
"I was struggling in the second set, love-forty down on my serve. If he makes that point, it is even more difficult."
Sinner will face Hungarian Fabian Marozsan in the next round, while Zverev takes on Italian Lorenzo Sonego.