Turkish President Recep Tayyip Erdogan says his country will send troops to Libya at Tripoli's request as soon as January, a move that could put them face-to-face with Kremlin-linked mercenaries allegedly fighting in the troubled North African country.

An official in Tripoli confirmed on December 26 that a formal request had been made to Ankara for the Turkish military's air, ground, and sea support.

Libya's UN-recognized Government of National Accord (GNA) in the capital, Tripoli, is struggling to maintain control against General Khalifa Haftar's eastern-based Libyan National Army, which is reportedly backed by Russia, China, Egypt, the United Arab Emirates, and Jordan.

The GNA was set up in 2016 as part of a UN-brokered deal after Libya was plunged into chaos following the ouster of longtime dictator Muammar Qaddafi in a 2011 NATO-backed uprising.

Moscow has warned Turkey against its pending deployment to Libya.

But Erdogan has rejected Russian criticism and said Turkey will not be silent over mercenaries from the Kremlin-linked Vagner private security firm supporting Haftar.

Moscow has not confirmed the Vagner group's presence in Libya nor whether it has supported the fighters.

"Russia is there with 2,000 Vagner [fighters]," Erdogan said, also referring to 5,000 fighters from Sudan in Libya.

"Is the official government inviting them? No," Erdogan said. "They are all helping a war baron [Haftar], whereas we are accepting an invitation from the legitimate government of the country. That is the difference," he said.

Representatives for Haftar's forces could not be reached for comment.

Haftar's fighters have not been able to reach central Tripoli but have slowly advanced to the southern suburbs with the help of Russian and Sudanese forces, diplomats say.

Meanwhile, the White House on December 26 said President Donald Trump held a phone conversation with Egyptian President Abdel Fattah al-Sisi in which the two leaders "rejected foreign exploitation" regarding Libya, without specifically mentioning the foreign powers.

"The leaders...agreed that parties must take urgent steps to resolve the conflict before Libyans lose control to foreign actors," the White House said.

Sinan Ulgen, a former Turkish diplomat and chairman of the Center for Economics and Foreign Policy Studies, told Reuters that Russian mercenaries had put more pressure on the GNA and "accelerated this quid pro quo between Tripoli and Ankara."

"So the troop deployment must happen right away, but the risk is that Turkey is being sucked into a military game where the only path is more engagement and escalation," he said.

With reporting by Reuters and AFP