1) The first thing you need to do is ask yourself why it is so important to break that habit. Breaking the bad habit and forming a good one has to be worth your while or else you won't commit to it. You have to want it!
2) You may want to ease into it. For example if you want to stop eating junk food, you may want to gradually decrease your intake of the bad stuff. So if you are eating 10 cookies a day, cut down to 8 and then 5 etc.
3) 30 days- There has been a lot of research that supports the fact that it takes 30 days to break a habit or create a new one. I actually tried this and I can tell you that it does work. I used to drink soda constantly. It was usually diet soda but I knew it still wasn't good for my body. I thought to myself " It's only 30 days. I can do that" and I did it! That's the key: don't think beyond the 30 days. I would also suggest marking off each day of your success on a calendar. I actually used happy face stickers. You're never too old for stickers LOL About 14 days in I found that I actually wasn't craving the soda like I usually would and it just kept getting easier after that. When the 30 days were up I continued to be soda free. I chose to stop drinking soda altogether but as I said earlier you can also chose to gradually cut back on something. I could have cut back to 2 glasses of soda a day for 30 days and then 1 glass for the next 30 days and then completely stopped it for the 30 days after that. Do what you feel will work for you.
Good Luck :-)