At least seven Nigerian soldiers were killed in a Boko Haram jihadist attack on a military base near the Niger border, the military said on Wednesday.
The Islamists and the army were engaged in a fierce battle on Monday in Metele, a village in Nigeria's northeast Borno State, the military said in a statement posted.
Seven soldiers died and 16 were wounded "in action" the army said, but military and civilian militia sources put the death toll higher.
"We lost 18 men in the fight which lasted for seven hours," a military officer told AFP, speaking from the Borno state capital of Maiduguri.
"Our men fought hard and dealt heavy blows on the terrorists but they were overwhelmed by the enemy who overran the base," said the officer who asked to remain anonymous because he was not authorised to speak on the incident.
A civilian militia assisting the military in fighting the jihadists said that on Tuesday 18 bodies of soldiers were brought to the garrison town of Monguno, 120km from the attacked base.
on Twitter and Facebook
"The fighting was fierce. It started around 16:30 and continued till 23:30," the militia man said.
Boko Haram suffered "heavy" casualties but managed to invade the base and take weapons, he said, adding that the jihadists destroyed "those they could not take away."
Boko Haram's Islamic State group-backed faction - known as Islamic State West Africa Province (ISWAP) - operates in the Lake Chad region and has in recent months intensified attacks on military bases in Borno and nearby Yobe states.
The attacks are seen as a sign of a hardline takeover in ISWAP by more radical lieutenants who executed the group's de facto leader over his willingness to hold peace talks with the Nigerian government.
Scores of soldiers have been killed, injured or missing in the latest wave of attacks but the military has repeatedly denied or played down losses to the jihadists.
More than 27 000 people are thought to have been killed in the nine-year Boko Haram Islamist insurgency that has triggered a humanitarian crisis and left 1.8 million people without homes.