Whether you're trying to kick a bad habit or establish a good one, 21Habit is a simple web app that operates on the principle that you need to repeat a daily activity 21 times before it becomes a habit. Although you don't have to, the truly serious can put up 21 dollars -- one dollar per day -- against your commitment that you'll make those changes.
Once you sign up, 21Habit asks you if you want to operate in "free mode", which doesn't require money, or "committed mode", where you put down $US21, or a dollar for every day you plan to establish (or ditch) the habit in question. Just tell the service what it is you resolve to do every day, and the app takes care of the rest.
If you're in free mode, 21Habit will just check in with you every day to make sure you're making progress towards your goal. If you're not getting anywhere, you can stop the habit and start a new one at any time. If you're in "committed mode", each day you succeed earns you a dollar. Each day you falter, a dollar is taken out of the pot available for you to earn back at the end of the challenge. When your challenge is completed (or you forfeit), the money you lost is donated to a charity of your choice, and you can start a new challenge.
21Habit isn't the only app that operates on the 21-day principle. Previously mentioned HabitForge does the same thing. The 21 day guideline is just that, a guideline. There's no guarantee that after 21 days you'll have no trouble taking the stairs or resisting when your coworkers ask you outside for a smoke, but it's a good way to get started making positive changes if you're planning them.