SANTA CLARA -- Wide receiver Dante Pettis worked his way back into the good graces of 49ers coach Kyle Shanahan during practices the past two weeks.

And if there was still any question about his status with the coaching staff, Pettis’ touchdown catch in traffic on Sunday made it official. His clutch grab provided Shanahan with one of his more emotional and fulfilling victories.

“I really wasn’t thinking anything,” Pettis said following the 49ers' 24-20 victory over the Pittsburgh Steelers. “When you’re in that moment, you just lock into the play, try to focus on the ball -- and that’s about it.”

Quarterback Jimmy Garoppolo looked for Pettis and showed confidence in threading the ball between two defenders for a 5-yard touchdown pass with 1:20 remaining in the fourth quarter for the winning points at Levi’s Stadium.

Said Garoppolo, "Dante is phenomenal in practice. I know you guys aren't seeing all that but he battles his ass off in practice. He has a great mindset of just when his number is called, he's ready. So you got to appreciate a guy like that. It's just having all that competitiveness and everything. You love to see that as a quarterback because you can trust that guy."

“He’s just gotten better each week,” Shanahan said, as the 49ers improved to 3-0 for the first time since 1998.

“We all know how he finished last year. He had a few bumps in the road throughout training camp. It’s been well-documented and talked about. I’ve been extremely impressed with how he responded since the first week of the season. He’s taken the challenge, been working as hard as anyone on the team.”

 

Shanahan said Pettis had a good week of practice in Youngstown, Ohio, before the Week 2 game at Cincinnati. But Pettis was held without a reception against the Bengals. On Sunday, he caught four passes for 20 yards against Pittsburgh, but also had a catchable pass deflect off his hands for a first-half interception.

When the 49ers needed a touchdown to avoid what could have been a disheartening, brutal loss, Shanahan and Garoppolo dialed Pettis’ number.

“It was good,” Pettis said. “There have obviously been a bunch of ups and downs. I know that’s part of sports. I’ve been around professional sports my whole life. I know what happens. You’re not just going to frickin’ be good every single day.

“Just being able to fight through that ... now I know what it’s like to go through that, it’s like, I know I can really do this thing. I know I’m here for a reason.”

Pettis, the son of former major league baseball player Gary Pettis, finished his rookie season strong and appeared to be a lock to be a starting wide receiver this season. But Pettis struggled in training camp this summer, and played just two snaps in the team’s Week 1 win at Tampa Bay.

Pettis, whose lack of urgency and aggression appeared to leave Shanahan frustrated, made the play to secure the contested pass and enabled the 49ers to pull off the emotional victory against the Steelers.

“It’s huge,” 49ers fullback Kyle Juszczyk said. “For Jimmy, for Kyle, to have that confidence to go to him when the game’s on the line, means everything. And for him to come up with it -- and that was not an easy catch. There were guys all over him, but (I’m) extremely proud of the way he responded. I didn’t want to stop celebrating with him out there.”

Garoppolo showed no hesitancy in going back to Pettis and trusting him to make the play that would rescue the 49ers’ offense from a five-giveaway day.

“It’s not really surprising to me that he threw it to me,” Pettis said. “It’s just Jimmy, he’s going to make a good decision and throw the ball where it needs to go. And he just made a good throw right there.”

[RELATED: Watch Jimmy G's game-winning TD pass to Pettis vs. Steelers]

The play -- and the support he received from his teammates -- clearly meant a lot to Pettis, a second-round draft pick in 2018.

“I think we have a pretty special team,” he said. “Everybody has each other’s back. When someone’s down a little bit, people are going to let them know, ‘Hey, we’re behind you. We know what you can do.' I never felt like anybody was looking at me like, 'this guy needs to step it up' or whatever.”