Underlying replacement cost profits at the group were 17.6 billion US dollars (£11.2 billion) in the year to December 31 after BP said the cumulative cost of the incident had reached 42.2 billion US dollars (£27 billion).
It still needs to settle the bill for civil claims but warned it would only be on “reasonable terms”, with the trial scheduled to start later this month.
Profits in its fourth quarter fell by a less-than-expected 20% to four billion US dollars (£2.5 billion), despite the group being hit with the biggest fine in US history after agreeing a 4.5 billion US dollar (£2.9 billion) penalty with authorities, which it will pay in instalments over five years.
BP said it was still assessing the impact of the terrorist attack at its joint venture in the In Amenas gas site in Algeria last month, but said it was committed to the country, where it has operated for 60 years and intends to resume production when it is safe.
BP said it had reached its target to raise 38 billion US dollars (£24 billion) from the sale of assets since the beginning of 2010 a year early. It made 6.8 billion US dollars (£4.3 billion) from sell-offs in the fourth quarter, excluding its 50% interest in the Russian TNK-BP venture to Rosneft.
In November it sold a range of North Sea oil fields to Abu Dhabi National Energy Company, Taqa, in a 1.1 billion US dollar (£687 million) deal.
But the sell-offs pushed production in its upstream business 7.1% lower and the group said it would also be lower in 2013, although its expects major projects in Angola, Australia, the Gulf of Mexico and Azerbaijan to come on stream.
Richard Hunter, head of equities at Hargreaves Lansdown Stockbrokers, said that while BP had made much progress during the full year, it was still “far from being out of the woods”.
He said: “Despite having disposed of 38 billion US dollars of assets to cover the known costs of the Macondo spill, the spectre of the impending trial casts a long shadow on prospects.”
But Sam Wahab, analyst at Seymour Pierce, said: “Following a difficult period for the company, we are beginning to see a resolution to BP’s various legal issues following Macondo.
“Investors may believe that this places the company in a robust financial position ahead of a significant year of upstream activity.”