Dwayne Johnson is revealing his struggles with depression.

Johnson shared on "The Pivot" podcast that he's had "three bouts of depression" over the years.

"The first time depression hit me I was at the University of Miami. I came in. I was balling out. I was going to be the only freshman to play. And at that time we were national champions, defending national champions," he explained, noting his excitement to fulfill his NFL dreams.

But then a shoulder injury ended his football career.

"That sent me in a tailspin," Johnson said. "I didn’t want to go to school.  I was ready to leave. I left school. I didn't take any midterms, and I just left. But the interesting thing, at that time, is I just didn't know what it was." 

Dwayne Johnson crosses his arms and showcases his muscles in a brown thin shirt on the red carpet

Dwayne Johnson shared that he's had "three bout of depression" over the years, beginning during his early football days at the University of Miami. (Jeremy Chan)

XFL OWNER DWAYNE 'THE ROCK' JOHNSON GIVES MOTIVATION PREGAME SPEECH BEFORE LEAGUE KICKS OFF

He continued, "I didn't know what mental health was. I didn't know what depression was. I just knew I didn't want to be there. Wasn't going to any of the team meetings. Wasn't participating in anything."

Johnson turned to wrestling, following in the footsteps of his father, wrestler Rocky Johnson

"I always say me playing in the NFL wound up being the best thing that never happened to me. Because it really helped shape and inform who I am."

The Rock at XFL

Dwayne Johnson revealed playing in the NFL was "the best thing that never happened to me." (Sam Hodde/Getty Images)

But that relief only comes from the benefit of hindsight, and he noted he faced other depressive episodes later in his life.

"At that time, it was a tough one for me, and again, I didn’t know what it was," Johnson said. "Years later, went through it again when I got a divorce, didn’t know what it was." 

Eventually, Johnson learned better how to cope and reach out for help when he needed it.

Dwayne Johnson and Kevin Hart together at an event

Dwayne Johnson says friendship, like the one he has with Kevin Hart, is "vitally important." (Photo by Jason Kempin/Getty Images)

KEVIN HART, DWAYNE JOHNSON PERFORM TIKTOK TORTILLA CHALLENGE IN VIRAL VIDEO: 'TRYING TO KEEP UP'

"Around 2017 or so, went through [it] a little bit but knew what it was at that time, and luckily at that time I had some friends I could lean on and say, ‘Hey, you know I feel a little wobbly now. I got a little struggle happening. I’m seeing the gray and not the blue,’" he said. 

Later in the podcast, the actor and wrestler discussed the importance of friendship, like the one he has with co-star Kevin Hart.

"Having friends is so vitally important as you just get a little older because you lean on each other. You can open up. If you're having a wobbly day, call me I'm there. Like that kind of stuff," he said.

More than anything though, Johnson credits his daughters, Simone Garcia Johnson (wrestling under the name Ava Raine), 21, Jasmine Johnson, 7, and Tiana Gia Johnson, 5.

"The saving grace for me has really been my daughters and being a girl dad," the "Young Rock" star said. 

Split screen of Dwayne Johnson with Simone Johnson, and Jasmine and Tiana Johnson

Dwyane Johnson credits being a "girl dad" to daughters Simone, left, Jasmine and Tiana, right, with giving him perspective (KENA BETANCUR/Instagram )

CLICK HERE TO SIGN UP FOR THE ENTERTAINMENT NEWSLETTER

"That’s been the saving grace because you look at them, and you realize, really this is what it’s all about. You look at the alternative to, how am I going to respond in this moment? What’s the best way that I can respond in this moment? Not now — they’re too young — but down the line, how I can help them. And this is how I responded to the moment, and hopefully this will help you guys as well."

The "Black Adam" star also shared clips from the podcast episode on his social media, encouraging people to reach out for help if they’re struggling. 

"I’ve worked hard over the years to gain the emotional tools to work thru any mental pain that may come to test me. But years ago I didn’t know what mental health struggle was," Johnson wrote.

APP USERS CLICK HERE

The Rock at the Black Adam premiere in Spain

Dwayne Johnson encouraged people to reach out for help if they’re struggling with their mental health.  (Aldara Zarraoa/WireImage)

He also noted that men especially need to open up more. 

"As men, we didn’t talk about it. We just kept our head down and worked thru it. Not healthy but it’s all we knew."

CLICK HERE TO GET THE FOX NEWS APP

"If you’re going thru your own version of mental wellness turning into mental hell-ness, the most important thing you can do is talk to somebody."

He continued, "Having the courage to talk to someone is your superpower. I lost two friends to suicide. Talk to someone. Despite how you may feel, you’re never alone."