(CNN) — Chris Evans almost passed on “Captain America.”

The actor, who rocketed to fame playing the Marvel superhero, said he originally did not want to take the role because he had been dealing with severe anxiety for several years and questioned his acting pursuit.

On Monday’s episode of The Hollywood Reporter podcast “Awards Chatter,” Evans spoke about his mental health and his first experiences with anxiety, which began around the same time as his major film debut in 2007’s “Human Torch in Fantastic Four: Rise of the Silver Surfer.”

“That was back when the superhero thing was just taking off. I had just been dumped and I needed it,” he said.

Evans said started having panic attacks while filming “Puncture” in 2010.

“It was the first time I started having mini panic attacks on set,” he said. “I really started to think, ‘I’m not sure if this [acting] is the right thing for me, I’m not sure if I’m feeling as healthy as I should be feeling.'”

By the time Marvel asked him to test for the role of “Captain America,” in 2011’s “Captain America: The First Avenger,” he turned them down.

Marvel came back, Evans said, and offered the role outright.

It took talking to his therapist, family and fellow superhero “Iron Man” star Robert Downey Jr. to say yes to the role.

“It was the best decision I’ve ever made, and I really owe that to [Marvel chief] Kevin Feige for being persistent and helping me avoid making a giant mistake,” Evans said, adding, “To be honest, all the things that I was fearing never really came to fruition.”

(Copyright (c) 2024 CNN. All Rights Reserved. This material may not be published, broadcast, rewritten, or redistributed.)

Join our Newsletter for the latest news right to your inbox