The failure of United Parcel Service Inc. and FedEx Corp. to deliver packages in time for Christmas has exposed the perils of retailers promising to get last-minute gifts to customers.

Chains from Kohl's Corp. to Amazon.com Inc. to 1-800- Flowers.com Inc. offered gift cards and refunds after angry shoppers took to social media to vent their frustrations at the missed shipments. On its website, UPS said the volume of last-minute air packages exceeded its capacity to process them.

Merchants battling for market share during a ho-hum holiday season have been trying to outdo one another with deep discounts and promises that shoppers can wait as long as they want to order gifts online. While analysts say the shipping snafu is unlikely to make Americans abandon online shopping, they say parcel-delivery companies will have to boost capacity and retailers might have to seek alternatives to prevent a recurrence.

"We always have last-minute Charlies, but this year even people who normally complete shopping earlier completed shopping later," said Marshal Cohen, chief retail analyst at market research firm NPD Group.

Said Craig Johnson, president of Customer Growth Partners LLC in New Canaan, Conn.: "You had a perfect storm of events from the consumer side, the retailer side and the shipping side. … Normally those kinds of schedules are all kind of prepared or coordinated with the carriers."

Barnesville, Minn., resident Bernadette Odden ordered videos for one of her daughters on Dec. 21 from Amazon, which promised to deliver them on Christmas Eve. They never arrived. Odden, 35, called Amazon and received a $20 credit, which she immediately cashed in for a camera.

"I don't think Amazon should take the fall for UPS' screwups," she said. "From now on, I will possibly check which courier is being used."

UPS is examining what caused the delayed air shipments, company spokeswoman Peggy Gardner said.

"We're looking at all aspects this year and talking with our shippers," she said. She declined to discuss the number of shipments that missed the scheduled delivery day.

In an e-mail, FedEx said it had shipped 99 percent of its ground deliveries on time and didn't specify a percentage for its air shipments.

'Rewarding bad behavior'

While online sales were softer than expected the week before Christmas, that can be explained in part by retailers piling on discounts earlier, pulling forward sales in a season that was six days shorter than last year.

UPS' status as the world's largest package-delivery company wasn't enough to absorb rapidly changing consumer behavior. Americans are waiting longer and longer to pull the trigger on purchases, said Marshal Cohen, chief retail analyst at NPD Group, a Port Washington, N.Y.-based research firm.

"We have watched retailers groom the consumer to wait," he said. "It's like rewarding bad behavior. You're saying to the consumer, 'The longer you wait, the better the deal, don't be fooled.' "

Putting further pressure on the shipping companies, retailers trying to compensate for a "mediocre" shopping season extended their order cutoff so procrastinators could still receive their purchases on Dec. 24, Johnson said.

During peak periods, shipping companies add trucks and aircraft and hire thousands of temporary workers.

UPS and FedEx "may need to increase investments to handle such volume surges," Anthony Gallo, an analyst at Wells Fargo & Co., wrote in a note to investors. "The 2014 Thanksgiving and Christmas calendars will be similar to 2013."

Merchants — even Amazon, which has spent billions on fulfillment centers — rely on parcel-delivery companies.

"Amazon's mistake is they are a victim of their own success," said Michael Pachter, an analyst at Wedbush Securities. "They have given us such amazing service for so long that we rely on it and wait to make our orders."

The Associated Press contributed to this report.