The Nigerian army says it has retaken the north-eastern town of Baga, held by Boko Haram militants since January 3.
In a tweet from its official account, the army said there had been heavy casualties and that “mopping up” operations were continuing.
The army’s claim is yet to be verified, but sources said Baga was no longer under militant control.
Nigeria says 150 people died when Boko Haram took Baga and nearby Doron Baga, but locals said up to 2,000 died.
Nigeria, Chad, Cameroon and Niger recently formed a military coalition against the Islamist militants.
It is not yet clear whether other armies were involved in the recapture of Baga. However, the Chadian army spokesperson told the BBC’s Thomas Fessy that there had been no involvement from his country’s troops.
Boko Haram controls of much of Nigeria’s north-east, and the group has killed thousands of people and abducted hundreds in its bid to establish an Islamic state.
In recent months it has carried out cross-border raids in neighbouring Chad, Cameroon and Niger, attacking villages and military bases.
The Nigerian army has been criticised by its failure to tackle the militant group, although it has recaptured some territory in recent weeks.
Last week, Nigeria retook the north-eastern towns of Monguno and Marte from the group.
The massacre at Baga is considered to be the worst attack of Boko Haram’s six-year insurgency. Thousands fled across Lake Chad when the assault began and have since taken refuge in Chad.
Earlier this month, presidential elections were delayed for six weeks over security concerns.
The electoral commission said it made the decision after the security agencies advised there would not be enough troops available to guarantee the safety of voters.
President Goodluck Jonathan says the election will take place on March 28. However, critics loyal to the opposition say they fear Mr Jonathan, who is running for a second term in office, will use the delay to hold on to power.
The election is seen as the most closely fought since the end of military rule in 1999.