United Airlines reported a quarterly loss but said it is hopeful about a long-term recovery in travel demand.

United Airlines reported another quarterly loss Wednesday on the lingering drag from COVID-19 but offered an upbeat outlook on a travel comeback later in 2022 and in future years.

The US carrier acknowledged that it is beginning 2022 "with a scaled-back schedule" following the latest uptick in virus cases, but will "nimbly ramp up" capacity later in the year, according to a news release.

"While Omicron is impacting near-term demand, we remain optimistic about the spring and excited about the summer and beyond," said United Chief Executive Scott Kirby.

United reported a fourth-quarter loss of $646 million, about a third of the loss from the year-ago period, but far from the $641 million profit in the 2019 period.

Revenues were $8.2 billion, more than twice the level in 2020 but a 25 percent drop from the figure in the 2019 quarter.

The period covered by the release started buoyantly, with airlines seeing increased bookings as COVID-19 vaccinations were rolled out and most of the US economy reopened.

But hopes dimmed later in the quarter as the Omicron variant surfaced as a major worry, prompting thousands of flight cancelations over the holidays because US carriers temporarily lost airline staff who were infected.

United projected its first-quarter capacity will be down 16 to 18 percent compared to 2019 levels. It also expects 2022 capacity to be below the level of 2019.

Shares of United fell 1.4 percent to $43.79 in after-hours trading.