Daimler joined German rival Volkswagen in defying the pandemic to post better than expected results for 2020, off the back of a strong recovery in the global car market led by China.

Preliminary figures released by the maker of the Mercedes brand on Thursday showed earnings before interest and taxes stood at more than €6.6bn, beating analysts’ estimates of about €5.2bn for the year.

That figure compares with €4.3bn in 2019, although the company booked €5.4bn in one-off legal liabilities during that year, including more than €4bn in relation to the alleged manipulation of diesel emissions tests.

The Stuttgart-based company added that, thanks to aggressive cost-cutting and “expected good underlying demand”, it expected to improve on these figures in 2021, assuming there were no further Covid-19 lockdowns.

Daimler’s announcement comes after Volkswagen said it had made operating profits of about €10bn last year, despite fears at the start of the Covid-19 crisis that it would end 2020 in the red.

VW’s earnings from China, its largest and most profitable market, will largely be reported separately, giving a boost to that preliminary figure.

Munich-based BMW on Wednesday said its free cash flow for 2020 stood at roughly €3.4bn, up from €2.6bn the year before and exceeding market expectations. In the early stages of the pandemic, the company had warned that it might make no annual profits in its automotive unit.

All three German carmakers have benefited from an unexpected recovery in car sales towards the end of the year partly because of pent-up demand after months of lockdown, and subsidies in several large economies.

Sales in Asia have been particularly strong. Towards the end of last year, Daimler boss Ola Källenius hailed the company’s rebound in China, saying it was almost “too good to be true”. BMW sold almost 780,000 vehicles in the country last year, an increase of almost 7.5 per cent on 2019.

The car sector as a whole is expected to suffer a 15 per cent drop in sales worldwide for 2020, according to IHS Markit, far better than the 25 per cent predicted in the middle of last year.

Daimler, which is set to publish its annual figures in full on February 18, warned that a shortage of semiconductors, which has forced many large carmakers to cut production in recent weeks, would “probably impact” its results for the first three months of 2021.