DAKAR, Senegal -- Senegalese troops charged into neighbouring Gambia late Thursday in a show of force to oust longtime ruler Yahya Jammeh after he failed to step aside when his mandate ended at midnight after losing the presidential election last month.

The troops moved in shortly after Adama Barrow was inaugurated as Gambia's first new leader in more than 22 years at the country's embassy in neighbouring Senegal after a final effort at diplomatic talks with Jammeh failed to secure his departure.

Senegalese military spokesman Col. Abdou Ndiaye confirmed to The Associated Press that the first West African troops had crossed into Gambia and were on their way to the capital, Banjul. AP journalists saw at least 20 military vehicles gathered at the border town of Karang.

In his inaugural speech, which took place under heavy security, Barrow called on Jammeh to respect the will of the people and step aside. The new president also called on Gambia's armed forces to remain in their barracks as the regional military intervention got underway.

Outside Gambia's embassy in Dakar, Baal Jaabang held up a freshly framed portrait of Barrow, already printed with the words: "His Excellency Adama Barrow, President of the Republic of Gambia."

"I'm extremely delighted, so wonderfully happy today," he said. "But now the situation risks moving into fighting. No Gambian -- in the diaspora or back home -- wants our country to face fighting."

Barrow had come to Senegal last week at the urging of West African mediators, who had feared for his safety amid the political crisis.

He arrived at the embassy to cheers of joy from hundreds of Gambians who had gathered, with national flags, for a glimpse of the new president.

"Our national flag will now fly high among the most democratic nations of the world," Barrow said after the ceremony.

Barrow was declared the winner of the Dec. 1 election and at first was congratulated by Jammeh in a phone call aired on state television. But once it was suggested that Jammeh could face criminal charges linked to his long rule, he backtracked and challenged the vote in court, alleging irregularities.

Jammeh on Thursday remained at his official residence and intended to stay there, said an official close to the administration who was not authorized to speak to reporters. If the regional force is going to arrest Jammeh, it will have to be there, the official said.

Many of Jammeh's loyalists will resist, the official added.

But there were signs that some in Gambia's military might not put up a fight. One soldier with close knowledge of the situation said several barracks had indicated they would support Barrow. The soldiers spoke on condition of anonymity because they were not authorized to speak to reporters.

Gambia's army is estimated at well below 5,000 troops.

Alex Vines, head of the Africa program at Chatham House in London, said Jammeh may try to cling to power for a few more days but was becoming increasingly isolated.

"After the inauguration of Adama Barrow, the trickle of power flowing to him will become more of a flood," Vines said. "Jammeh clearly believes leaving Gambia in a hurry is an option -- his aircraft has been on standby at Banjul airport for two weeks," he added.

African nations began stepping away from Jammeh, with Botswana announcing it no longer recognized him as Gambia's president. His refusal to hand over power "undermines the ongoing efforts to consolidate democracy and good governance" in Gambia and Africa in general, it said.

The African Union earlier announced that the continental body would no longer recognize Jammeh once his mandate expired.

Congratulations to Barrow began pouring in, including from British Foreign Secretary Boris Johnson and the head of the African Union, who said she would invite Barrow to attend the continental body's summit late this month.

Inside Gambia, many people hugged and cheered, chanting "New Gambia, new Gambia!" as news of the inauguration spread.

"It's unbelievable! Today I can say anything. I am the happiest man on earth," said Lamin Sama, a 35-year-old in Banjul. "For 22 years we couldn't say anything, we were like slaves."

- Associated Press writers Robbie Corey-Boulet in Abidjan, Ivory Coast; Edith M. Lederer at the United Nations; Ahmed Mohamed in Nouakchott, Mauritania; and Bashir Adigun in Abuja, Nigeria and Carley Petesch contributed to this report.