Eric Dane has come clean about being axed from Grey’s Anatomy in 2012 — he now admits producers fired him because he was high most of the time.

Until now, the Bad Boys: Ride or Die actor, 51, has always claimed he ditched his gig as Dr. Mark “McSteamy” Sloan in 2012 because he was looking to do “something different.”

But he recently revealed he was let go after eight seasons in part because of his drinking and drug use. “If you look back at the whole eight years on Grey’s Anatomy, I was f–ked up longer than I was sober,” he says.

Although he had struggled with substance abuse in the past, he was sober when he joined the show in its second season in 2004. He suffered a relapse during the 2007 writers’ strike, however, and producers eventually decided he wasn’t worth his hefty paycheck.

“I wasn’t the same guy they had hired, so I had understood when I was let go,” he says.

“In some ways, Eric feels like he killed the golden goose with Grey’s, getting wrapped up in his personal struggles,” a friend exclusively tells Closer. “But he isn’t bitter — he’s just happy to be clean and sober now.”