Deep discounts and the warmest July weather in decades brought U.S. shoppers to malls, helping many retail chains report healthy monthly sales increases.

The 25 chains tracked by Thomson Reuters reported a 4.4 percent gain in sales at stores open at least a year. That met analysts' expectations for July, the month that kicks off the important back-to-school season.

Warehouse clubs Costco and BJ's and luxury chain Saks posted some of the biggest gains, highlighting the bifurcation in the consumer-driven U.S. economy. Department store and other retailers that cater to the middle were among those that disappointed.

The folks that are doing well economically are going to continue to spend at a pretty good clip, and the families that have less means are going to continue to pick and choose and only spend on what they need versus what they want, said Alison Paul, leader of advisory firm Deloitte's U.S. retail practice.

The July figures made some chains, such as Target Corp, optimistic about demand heading into the back-to-school season, the second-biggest selling period of the year after Christmas.

Back-to-school sales are off to a solid start, contributing to our confidence in the strategies we have in place and our ability to execute them, Target Chief Executive Officer Gregg Steinhafel said on Thursday.

The discounter reported a better-than-expected 4.1 percent rise in same-store sales and forecast a low to mid-single-digit percentage increase in August same-store sales.

My mom is paying the bills, and they're telling me that they need to cut back on me spending all this money on me buying clothes, said Ed Rush, 15, who was shopping at a Target store in Chicago.

Costco Wholesale Corp reported a 10 percent rise in total July sales at stores open at least a year, beating the analysts' average estimate of an 8.6 percent increase.

BJ's Wholesale Club reported a 9.2 percent same-store sales rise, while analysts only expected 6.6 percent growth.

U.S. consumer sentiment fell in July to its lowest point in more than two years as anxieties over stagnant wages and unemployment deepened, a survey showed.

That may have shown up on retailers like Kohl's Corp and Gap Inc, which disappointed investors.

Same-store sales reports capture only part of the retail economy. Industry leader Wal-Mart Stores Inc and other major retailers such as Best Buy Co Inc and do not report monthly sales.

The apparel sector reflected the mixed fortunes for retailers in July.

Teen-oriented chains Hot Topic and Wet Seal blew past estimates, with Hot Topic forecasting a smaller quarterly loss than Wall Street was expecting.

But rival Zumiez Inc missed July sales expectations, blaming the weakness on lackluster sales of accessories.

The United States had its warmest July in 50 years, according to Planalytics, a company that tracks weather for businesses.

Recent hot weather has driven consumers to the malls, aiding in the clearance of spring and summer merchandise, Barclays analyst Robert Drbul said.

(Reporting by Dhanya Skariachan and Roy Strom in New York, Jessica Wohl and Eunju Lie in Chicago, Alistair Barr in San Francisco, Abhishek Takle, Arpita Mukherjee, Meenakshi Iyer and Mihir Dalal in Bangalore; Editing by Lisa Von Ahn and Bernard Orr)