You have some extra money left over after paying your bills, and you know you should sock it away in savings or use it to pay down your credit card. But this new restaurant just opened down the street, or you really could use a weekend away, and you just don’t have the willpower to resist some short-term gratification.

If you find yourself lacking in willpower when it comes to meeting long-term financial goals, you’re not alone. The good news is there’s an easy solution.

Use a commitment device

Commitment devices help us lock into good habits we might otherwise struggle to stick with. For example, if you find yourself spending extra cash too often, signup to have money automatically deducted from your paycheck or checking account before you can spend it. With time, you’ll be closer to your financial goals.

The main reason commitment devices work is our brains are wired in two different ways: one set of wiring for our short-term selves, and another for our long-term selves.

The long-term wiring helps us do what’s good for ourselves in the future, while the short-term wiring often wants us to enjoy ourselves in the moment. Signing up for future deductions takes short-term, impulse spending out of the equation and locks us into a good habit.

A question of willpower

Some of us have more than others, and some days we have more willpower than other days. With commitment devices we take our level of willpower out of the equation, so “every month we don’t have to force ourselves through an act of will to make the right decision,” says Navy Federal Corporate Economist Robert Frick.

You likely can link accounts to make these automatic transfers through your employer, or through your bank or credit union. All it takes is a little paperwork today to put yourself on the road to higher savings or lower debt tomorrow. Frick adds that debt can be particularly hard to pay down, because sometimes it’s a source of shame. But, he says, if you can imagine your long term self out of debt, how great that’s going to feel.

Automatic deductions are a classic example of a commitment device, but there are others. For example, you can write a check to a cause you really dislike, and hand it to a friend with the instructions to mail that check if you haven’t reached your goal. The psychology behind this is distaste is so powerful an emotion you’ll do just about anything not to experience it.

Get by with a little help from your friends

Another way to lock in a goal is to announce it publicly to a group of people you know, and regularly update your progress to them. That will give you not only a dose of peer pressure, but also some peer support

And to make that check commitment device work even better, make it a contest. Have your friend that’s holding your check send you a check for a cause they don’t like that you’ll mail if they don’t reach their goal. A little competition can be very motivating.

There are a number of websites that can help you with both the peer and punishment types of commitment devices. Some have coaches that monitor your progress, and others make you pay only if you don’t meet your goals. Just do a search for “online commitment devices.”

If you’re looking for more ways to meet your financial goals, don’t hesitate to partner with your bank or credit union. There’s a good chance they have resources online and would be happy to work with you to meet your financial goals. Working with a financial institution you trust can give you confidence along your savings journey.