Yeah, it was a culmination of a bunch of different things for me. I've been trying to get sober for like 12 years now, but have only really strung together like six months at most. This was a couple years ago. I'm sober today now, thankfully. It took me losing my marriage, losing my employment/finances and independence, dozens of jobs, the death of someone I loved dearly, jail, DUI and legal issues, and basically losing my mind before it sunk in that I really can't take drugs at all if I want to have a chance of living. I have no other choice than getting better, honestly. I've had periods of addiction to every class of drug but cocaine and alcohol have been the hardest for me to stop. I had something of a spiritual awakening too, which wasn't a matter of reading spiritual texts so much as putting aside my own selfish bullshit and putting faith in something greater than substances or material desires.
Not everyone has to go through all that though. If someone is finding that their drug or alcohol use is disrupting their life, I'd suggest they check out a 12 step meeting or try and see a counselor to maybe get to the bottom of why they're using so heavily. I've never done anything moderately, from sex to gambling to drugs.
It helps to find a cause greater than yourself, and work on that if you're truly working towards recovery.