Every once in a while, I let my mind wander: What if I didn’t eat sweets? What if I didn’t drink alcohol? What if I was as committed to eating well as I am to exercising regularly?

Then I laugh and think: Get real, Anna! What’s a girl to live for without cinnamon dolce lattes, happy hours, and hot fudge? That’s right: Not much.

But recently, I let myself consider these “what-ifs” more realistically. My first Olympic-distance triathlon was coming up, and I’d been training for months. Why undermine my hard work with empty calories? I decided that, if only for the week leading up to the race, I would cut out sugar and alcohol. How hard could it be?

Here’s how hard: On day one, I was at a beach house with friends. It was raining. What do you do at the beach when it’s raining? Drink! Go on a bar crawl! Try a Bloody Mary with Old Bay, another with Tabasco, and another with bacon! Sip on wine while cooking dinner and hard cider while eating it! Day one: Super fail.

Clearly, commitment isn’t my strong suit. So I turned to stickK, a pretty genius site that I’d been researching for an article about technology and behavior change. The program has you set a goal—lose 10 pounds, call your mom weekly, learn French, whatever—and then hand over your credit card information. If you slip up, the site donates your money to a friend, foe, charity, or anti-charity (an organization whose cause you hate). If you stay on track—as reported by you and the person you name your “referee”—your money stays in the bank.

The site works because the founders—economists from Yale—know a heck a lot about human behavior. For example, research shows you would rather avoid losing something than gain something, a concept called “loss aversion.” So, in theory, stickK is more motivating than a workplace wellness program that awards $20 for losing weight. What’s more, stickK loops in layers of social accountability. If my commitment was only inside my mind—as it was the first go-round—I could say yes to a drink without anyone knowing I was supposed to say no. But once I made my promise public, I had face to save. That’s right, stickK knows you have pride—and it’s not afraid to make you use it.

So I named my goal, recruited the help of my boyfriend (my “referee”) and my friends (my “cheerleaders”), and dangled my $20 over an organization that—let’s just say—makes my blood boil. Here’s how my week went:

Day One (Take Two)

Black coffee and a no-sugar cereal were bearable, especially with almond milk, which satisfied my sweet tooth. Success! But it was Sunday and temptations were scarce. The real willpower tests were yet to come.

Day Two

Early in the day, I warned my friend that I wouldn’t be drinking at the happy hour we had planned that evening. But because he (like me) believes there’s nothing “happy” about boozeless bar time, we decided to take a rain check. Day two: Diet success, social life fail.

Day Three

Another friend and I had been planning on catching up over frozen yogurt, but now that was out of the question. Or was it? Isn’t fro-yo pretty much just really cold regular yogurt? In fact, isn’t it actually good for you, with all those probiotics and stuff? Deep questions like these are why you have a ref. So I presented my case to my boyfriend, who ruled somewhere along the lines of “hell no.” Harsh call, ref.

But I wasn’t about to let my anti-charity win. So my friend and I agreed to go for a jog instead. It was healthier than the healthiest of fro-yos and served the same purpose: one-on-one time to catch up. Day three: Commitment success and social success.

Day Four

The day’s post-work plan—a birthday celebration at a favorite Mexican joint with great margaritas—was the ultimate test. What was this? The Truman Show? Were the producers throwing in this goal-deterring roadblock just to thicken the plot and watch their heroine sweat? If so, it worked. But after turning down my first few drink offers, I learned that good friends (and good guacamole) can make any party fun—even if you’re only drinking water. And unlike the birthday boy, I felt great the next day. Success.

Day Five

With my triathalon two days away and no social engagements for the evening, day five was easy as pie—er, make that pineapple.

Day Six

You shouldn’t be tempted to drink the day before your race, but I’ve been known to give in before. And this time, the cozy mountainside cabin I stayed in—complete with a hot tub—was a serious tease. But there was no turning back now. Tomorrow, I reminded myself, the wonderful world of wine and chocolate would be mine.

Race Day

I felt good, raced well, and thoroughly enjoyed my post-race chocolatey trail mix and champagne. Success!

But the greater success was discovering that I can in fact go a day (even six!) without my precious flavored creamer, that being the sober one at the party can be fabulous entertainment, and that your friends (and your foes) can be great motivators in helping you reach your goals. I also learned that there’s no “good” time to make that big change you’ve been hoping to make. Life will always be full of temptation—but like muscles, willpower needs to be exercised to get stronger. Some of us just need a little boot camp to get started.

Photo of woman running courtesy of Shutterstock.