Mexico's state-run energy giant Pemex reported losses of $14.3 billion for 2016 on Monday, halving its losses from the previous year and saying "austerity" measures were starting to pay off.
Pemex, which has not posted a profit since 2012, has struggled through a period of low oil prices and sweeping energy reforms launched by President Enrique Pena Nieto.
The annual loss was relatively good news compared to 2015, when the company lost some $32 billion.
Pemex said it had slashed operation costs by 26 percent last year, and maintained production levels at 2.15 million barrels a day.
It also got a boost from recovering oil prices and a cash injection of $4.2 billion from the government in April to help the struggling firm.
"All of this is the product of implementing austerity policies to achieve greater efficiency and discipline," said chief financial officer Juan Pablo Newman.
Seeking to stave off a financial catastrophe, Pemex shelved $3.6 billion in investments early last year and implemented $5.5 billion in budget cuts.
The company has cut its work force by 11,000 jobs.
Pemex has struggled to stem a decade-long slide in production, which peaked at 3.4 million barrels per day in 2004.
In 2014, Pena Nieto enacted a landmark energy reform bill that reopened the country's oil and gas sector to foreign investors in a bid to kickstart production and boost the economy.
Pemex generates about 20 percent of the Mexican state's revenue.