A strong stock market and better pay growth has Americans more confident heading into this holiday season: Several studies indicate we’ll spend more — and borrow more — to fuel our shopping through the end of the year.

According to the National Retail Federation, October activity (excluding cars, gas and restaurant spending) was up by 5.6 percent, year-over-year unadjusted, and all signs point towards a similarly robust holiday season. An NRF survey of more than 7,300 American adults found that the average shopper will crack the four-figure mark, with people saying they will spend an estimated average of $1,007.24 during the holidays, a 4.1 percent increase over last year.

Much of that spending momentum, though, is fueled by debt: Shoppers today are more willing to finance their holiday splurges, and if past history is any guide, a large number will borrow more than they intended before the year comes to a close.

According to a study by WalletHub, 35 percent of shoppers plan to spend more than $500 over the holidays, up two percentage points from the year earlier, and roughly one in five say they expect to still owe money for this spending into February or later.

But people tend to be overly optimistic about how much they spent and how quickly they can pay it off, said WalletHub analyst Jill Gonzalez. “What actually happens is more like three in five end up owing,” she said.

“People are continuing to take on more debt because they see economic numbers doing better,” Gonzalez said. “All these things do subconsciously influence our spending, especially this time of year… It’s a sense of groupthink.” Even if individual Americans haven’t seen their financial situations change much, Gonzalez said there is a tendency for people to assume that their raise or other big break is just around the corner. “It’s banking on something you’re not sure of and spending anyway.”

A couple of factors this year mean that, despite a robust economy, more Americans might find themselves struggling to pay off their debts after the holiday season is over.

“When it comes to paying off holiday bills, people count on a couple of things. You’re looking for tax refunds, you’re looking for your annual bonus,” Gonzalez said. But tax experts warn that changes to IRS withholding tables mean people could find themselves with a smaller refund on their 2018 taxes, and although wage growth is improving overall, the corporate tax cuts have not translated into higher pay across the board as supporters predicted: A survey by human resources consulting firm Mercer found that a whopping 96 percent of businesses said they had no plans to funnel tax cut savings into higher salaries for 2019.

A survey by Credit Karma found similar — if equally over-optimistic — expectations, with 22 percent of respondents saying their holiday spending typically puts them in the red.

Ironically, the factor that pushes people into debt over the holidays can be the prospect of a good deal: Credit Karma found that although more than half of survey respondents shopping over Black Friday and Cyber Monday have a budget, 63 percent of those would toss their budget for a really good deal, and 45 percent said they’d go into debt if a discount was deep enough.

“It’s a really interesting time to be a consumer in this country. It’s never been easier to buy items you want, it’s never been easier to spend money — we’re surrounded by more opportunities to spend and we are bombarded online with specially targeted ads that are designed to make us spend more,” said Maizie Simpson, Credit Karma data editor.

“When you dig into this a little bit further, you find that Americans just aren’t great at budgeting this time of year. I think you have this phenomenon where people have budgets, but I don’t know if they’re necessarily writing them down and sticking to them,” she said. “When it comes down to practice, they’re not truly holding themselves accountable.”

Other research indicated that this indeed could be the case. According to a survey from the Center for the New Middle Class from Elevate Credit, an online lender that targets subprime borrowers, roughly four in 10 shoppers who said they just had a general plan for holiday spending as opposed to a detailed budget said they overshot their spending goals.

This study also indicated that consumers whose credit scores are already lower may be disproportionately affected by the promise of a good deal, even if it actually is detrimental to their finances. Although 36 percent each of prime (those with credit scores of 700 or better) as well as non-prime consumers report spending more than planned over the holidays, shoppers with credit scores below 700 who say they spent more than planned were more likely than their non-prime counterparts shop sales or use coupons to try to save money.

“When you’re prepared to spend and you feel like you’re getting a good deal on something you probably have the feeling that you can spend a little more,” said Jonathan Walker, executive director of the Center for the New Middle Class. “People tend to think they’re doing a good job because they’re hitting the sales and coupons but they’re not paying attention to the top line.”