Lufthansa has cancelled nearly 900 flights after a last-minute legal bid to prevent a strike by pilots failed.

Germany's flagship carrier said 876 flights would be grounded on 23 November, affecting 100,000 passengers in total.

Pilots union Vereinigung Cockpit began its 48-hour strike at midnight after its demand for a 3.7% increase in pay over a five-year period dating back to 2012 was not met by Lufthansa.

Some 51 of the 876 flights that have been grounded are intercontinental, the carrier said.

Lufthansa had launched an eleventh hour legal bid to get an injunction against the strike but it was thrown out by a Frankfurt labour court.

Flights operated by Lufthansa's subsidiaries, including Eurowings, Austrian Airlines, SWISS, Brussels Airlines and Air Dolomiti, are not affected by the strike.

Customers who have had their flights cancelled can transfer or cancel their booking.

"Lufthansa apologises to all its customers that are affected by this strike," the German carrier said in a statement.

"The company is doing everything in its power to minimise the impact on passengers."

It added: "Lufthansa has offered mediation to Vereinigung Cockpit on a number of occasions, in order to resolve the wage dispute with the assistance of a neutral third party.

"VC has consistently rejected the offer. Instead, VC has now announced a strike that will hurt our customers and colleagues most of all."

"VC is ignoring the possibility of mediation and is avoiding its responsibilities as a social partner."

Vereinigung Cockpit has gone on strike more than a dozen times since mid-2014.

Lufthansa has been trying to cut down costs amid falling profitability and has offered VC pilots an annual pay rise of 2.5% over the six years to 2019 to resolve the dispute.

Meanwhile, a separate pay dispute involving cabin crews at Lufthansa-owned budget airline Eurowings led to around 60 flights being cancelled at Hamburg and Dusseldorf airports on 22 November.