It can be easy to lose track of your bar tab and spend far more than you'd planned.

But there are a few ways to budget your night while still having fun and experimenting with new cocktails.

Pay for drinks as you go (preferably with cash) and take advantage of happy hours and promotions on social media.

Most importantly, respect your bartender — they take care of their regulars who are friendly and patient.

Up there with parking tickets and jury summons lies another paper that can knock a smile from your face: a runaway bar tab.

But a night at the bar doesn't have to end in a such a sobering moment, as you try to recount just how many drinks led to your final tally. Here's how to have fun without experiencing a budgetary hangover, with intel straight from those who really know: the folks behind the bar.

1. Don't keep an open tab

Pay for each drink as you go.

Keep a tab open, and it can be all too easy to lose track of all the drinks you (and maybe even friends) charge to it. "That can be a real bummer of a surprise at the end of the night," says Brian Branaghan, who has been a bartender at Sidetrack in Chicago for 18 years.

In fact, Sidetrack doesn't keep customers' tabs open anymore — for each purchase, bartenders run a separate transaction. This policy makes customers more aware of each drink purchased, Branaghan says.

It also reduces the number of conversations between bartenders and their customers who, upon closing their tabs, don't remember spending so much, he adds. And it prevents a problem Sidetrack had, of customers forgetting to close their tabs and leaving debit and credit cards at the bar.

So if you plan on using plastic, take a note from Sidetrack and close your tab after each purchase. The steps of seeing the amount spent, handing over your card, signing the receipt and adding your tip can slow you down and help keep spending in check.

Or use only cash.

Similarly, handing over a $50 bill and receiving much smaller bills and coins in return can make you more mindful of spending. So consider bringing only the amount of cash you can afford to spend and leaving your plastic at home. (Or if having a card on hand makes you feel more comfortable in case of emergency situations, bring it, but pinky promise to leave it in your wallet.) Running out of cash is your cue to call it a night.

2. Swap in (cheaper) nonalcoholic drinks

Order water, seltzer or soda between alcoholic drinks to prevent overspending and overindulging. Branaghan says he and many bartenders tend to give such nonalcoholic drinks for free. "I reward responsible behavior," he says.

Of course, don't assume your bartender will do the same. But even if the Coke isn't free, it will be cheaper than if there were rum in it.

Follow your favorite bars on social media to know when they'll have special discounts. Reuters/Yves Herman

3. Take advantage of promotions

You can often avoid paying full price for drinks when you seek out happy hours, day-of-the-week specials and other promotions. When you see deals listed on menus or promo cards, Branaghan suggests snapping a photo on your phone so you remember for next Margarita Monday.

Many bars also promote specials on social media, Branaghan says, so follow your go-to establishments online.

4. Respect your bartender

Tap their expertise.

If the cost of a drink is unclear — say, a gin and tonic with Gordon's versus Tanqueray — don't be afraid to ask, says Clair McLafferty, author of "The Classic & Craft Cocktail Recipe Book" and bartender at The Essential in Birmingham, Alabama.

After all, these professionals know the products behind the bar, as well as their worth. So ask for suggestions about the best liquor for your budget, she says, either for your next drink or for your home bar. "You talk to your butcher; you talk to your mechanic," she says. "Why wouldn't you talk to your bartender?"

Treat them kindly.

Bartender PSA: No waving your cash or card at the bar or insisting you were next up to order. "That's going to get you thirsty — that's not going to get you a drink," Branaghan says. "We're not serving penicillin shots. It's not a life-or-death situation."

However, your bartender will probably notice if you're patient and treating him or her as a person, rather than a booze dispenser, he adds. While this may not save you money — although you can cross your fingers for a free drink or a generous pour — it may help you save face and earn some kindness in return.

As Branaghan puts it: "The friendlier you are, the more respectful you are to the establishment, and the more you patronize the place, the more the staff is going to be willing to take care of you."