Tyson Fury says racism directed at the travelling community fuelled some of his controversial outbursts and played a part in the mental health issues that he continues to battle.
Britain's Fury spent 30 months out of the ring from November 2015 and said he contemplated taking his own life.
During that period he apologised after being criticised for comments he had made about women and homosexuality.
"I started playing this part, being arrogant and cocky," Fury writes.
The 31-year-old, who is of Irish Traveller descent, says in his new book: "I eventually lost myself in this character.
"When I started out as a pro, I made a decision which on reflection played a big part in exacerbating my moments of despair.
"I went into the paid ranks off the back of an amateur career during which I was aware of racism against travellers. This made me an outsider and so I felt that for me to get the attention I needed to be an attraction in the sport, I had to play the outlaw.
"I felt I had to act out a role to seek publicity and to do that I had to be controversial and shock people with how I talked. To some degree it worked. But playing the role got to the point where I didn't know what was real and what was the act."
Speaking to BBC Sport Fury added: "The Mr Nice Guys, I don't remember them as they don't get a look in.
"This character I was playing to sell and fit in, to be liked, there comes a point where I couldn't do it any more. Wherever I was going I couldn't be me any more, I had to be Tyson Fury.
"I had lost the passion to be myself and would be this character all the time. The mask was welded to my face all the time."
Regrets over angry comments
Fury's most controversial comments followed his shock win over Wladimir Klitschko, ending the Ukraine fighter's 11-year unbeaten run to become unified heavyweight champion of the world.
In the aftermath of his win in Düsseldorf, Fury had said: "I'm not sexist. I believe a woman's best place is in the kitchen and on her back. That's my personal belief. Making me a good cup of tea, that's what I believe."
He also said in an interview it would only take the legalisation of paedophilia in addition to the decriminalisation of homosexuality and abortion to see "the devil come home".
His words led to more than 140,000 people signing a petition for him to be removed from the shortlist for the BBC Sport's Personality of the Year award.
"I confess I didn't react as I should have done and I regret how I came across at times," he says in his 'Behind The Mask' autobiography, which will be published on Thursday.
"I was angry and felt under-appreciated."
Fury recalls anxiety attacks in his teenage years as the moments when his mental health problems first became apparent. He also says he hit new lows in 2014 when he was forced to sell assets to cover the costs he faced when two fights with compatriot David Haye fell through.
But in the hours after his win over Klitschko he recalls feeling "empty". He explains that after the bout he also began to feel the impact of bottling up emotions following the death of his uncle and a miscarriage suffered by wife Paris six months into a pregnancy.
He says his wife, who he met when he was 17, looked set to leave him several times during a spell where he binged on alcohol and took cocaine but that she feared he might have taken his own life.
"I can't really put into words how much it means to me that Paris stuck with me and the pain it causes me when I look back to how low I brought her, because she didn't deserve it," says Fury.
Halloween turn and Wilder concern
Fury was diagnosed with bipolar and obsessive compulsive disorder in 2016.
"I had a massive anxiety attack and ended up in hospital," he told BBC Sport.
"A few people came down to see me and I was delirious. I was unwell for two months; I was terrified of everything. My dad came to live with me as I was too scared to live on my own. I couldn't sleep with the light off."
His weight reached 28 stone, and he recalls being dressed in a skin-tight skeleton costume on Halloween in 2017 as a turning point because he could hear people talking about him in a bar.
"I didn't take the mask off, I even drank through the mask," he says. "For the first time in a couple of years I thought to myself 'what are you doing here? Is this what your life has come to?'"
Asked about the incident by BBC Sport, he said: "I put a drink to my mouth and saw all young kids out - university age kids - and I thought what are you doing? I put the beer down and left and went home.
"I started crying for 20 minutes asking for help. I poured my heart out and got back up off the floor and felt like a new man."
Fury, who recently took part in a WWE pro-wrestling bout, hopes to face WBC world heavyweight champion Deontay Wilder in a rematch on 22 February.
He reveals both his wife and brother Shane wanted him to retire after witnessing the heavy 12th-round knock-down he suffered in a thrilling draw with American Wilder in December 2018.
Fury says he regards getting up from the canvas that night as encapsulating his journey from despair to a place back among the elite names of the heavyweight division.
The former IBF, WBO and WBA world champion encourages mental health sufferers to follow his own example in seeking professional help.
"I had to face the fact I was in denial about my behaviour at times and the lifelong fight I've had with depression," he adds.
"I know how dark it can get, but I also know there is light, there is hope."
If you or someone you know has been affected by a mental health issue, help and support is available at bbc.co.uk/actionline