Spending a long night at the blackjack table or online casino is fun, but it’s also work. Here are some tips to stay on top of your game throughout.

Winning at blackjack on a consistent basis requires use of a card counting system. And keeping count throughout multiple rounds, during several hours, over the course of a long night at the casino isn’t easy. It’s hard work, literally. Even if you aren’t counting, a long blackjack session is difficult.

Just as a spending a day at the office can leave you worn out, playing blackjack all night is mentally taxing and can lead to distraction. And distracted play at the table leads to blackjack strategy mistakes, lost hands, and a shrinking bankroll.

Sure, you think the adrenaline rush from playing blackjack will be enough to sustain your attention. And it will be, for a while. But staying alert doing a 3+ hour blackjack session requires a lot more than that.

Here are a few tips for staying focused while playing blackjack online or in a land-based casino:

#1: Go light on the alcohol and caffeine

There’s nothing wrong with having 1-2 cups of coffee or a few beers/cocktails/glasses of wine throughout the night. But taking a drink every time the waitress comes by is bad news. Counting cards drunk, or even slightly buzzed, simply isn’t going to work.

As for caffeine, too much will give you the jitters, making you nervous and mistake-prone. And loading up on coffee early in the night will lead to a crash later on. Drink water instead. Small sips of cold water will help you stay alert, and good dehydration is proven to keep the mind sharp.

You need to stay on an even keel throughout the night, which brings us to our next point.

#2: Get 7-9 hours of sleep per night (or day)

The life of a professional gambler is not conducive the sleep. Usually spending long nights at the casino or in front of the computer, many blackjack pros don’t get to bed until the early hours of the morning.

Combining later nights with familial obligations—or a day job—makes it difficult to find time to sleep. But because sleep deprivation means loss of focus, reduced cognitive functions, and terrible blackjack strategy, maintaining a steady schedule is crucial. Develop a plan for how you’re going to get a solid 7+ hours daily.

#3: Take a 30-minute break every two hours

Business guru Peter Bregman advises everyone to take one minute each hour to look up from their work. Taking a short mental break keeps stress minimal and allows us to feel refreshed when we get back to work.

A similar technique is useful when playing blackjack. If using a card counting system, you need to stay at the table until the shoe has been dealt. But you’d be well-advised to take a long break roughly every two hours.

Get up, stretch your legs, use the bathroom, have something to eat or drink—but remember, lay off the booze and caffeine!

#4: Keep a written log of each round

This is a little trick that not enough blackjack players follow, but it will do wonders for your game. Keep a small notebook with you, and while taking a break from the action jot down keynotes from the previous round.

Write down what worked, what didn’t, how the game was dealt, and what you did wrong. This will help you to spot holes in your game. You’ll also remember small details about the rules or mistakes made by the dealer that you can exploit later.

#5: Don’t eat heavy meals

It’s important to watch what you eat before and during a night of blackjack. The same principle applies whether you’re gambling at a land-based casino or playing at a blackjack casino online. We’ve all tasted the deliciousness of a casino buffet, but lay off until you’ve finished playing!

Eating a big meal heavy on meat, fat, and dairy products will leave you bloated and sleepy. Not at all the state you want to be in when using a card counting system. If you do get hungry, have something small and light.

#6: Converse with other players, but not too much

The point of this blog post is to help stay focused while playing blackjack. That means zeroing in on the cards and playing each hand like it’s your last. Sort of. Playing like a half zombie/half robot gets tiring after a while.

It’s better for your mental faculties to have normal, human conversations with the dealer and other players at the table. That will help you stay relaxed and in a good mood. It will also keep the heat off your back.

If you are using a card counting system, it’s important to act natural, especially when it looks like the pit boss is on to you. The more you can act like a run-of-the-mill basic blackjack strategy player, the better.