The Nigerian army has regained control of Chibok, the northeastern town where more than 200 schoolgirls were kidnapped by Islamic extremists more than six months ago, said army officials.

The army wrested back control of Chibok on Saturday, 48 hours after it had been captured by the Islamic militants of Boko Haram, Nigerian army spokesman Brigadier General Olajide Olaleye told the Associated Press.

"Chibok is firmly in the hands of the Nigerian army." Olaleye told the AP. "Chibok is free. Secured."

He encouraged Chibok residents to return to their homes.

The town in Nigeria's northeastern Borno state had been captured by Boko Haram insurgents on Thursday night. Thousands of residents fled when the rebels entered the town shooting from pickup trucks and motorcycles.

Two days later Chibok was recaptured by troops of the Nigerian Army's 7 Division, said Colonel Sani Usman, a deputy director of army public relations.

Villagers around Chibok said they saw a large deployment of soldiers moving towards the town on Saturday morning.

Chibok is an enclave of mainly Christian families, some involved in translating the Bible into local languages, in the mainly Muslim north of Nigeria.

Although the army has regained control of Chibok, Boko Haram still holds several towns and cities in an area covering an estimated 20,000 square kilometers (7,700 square miles) where the insurgents have declared an Islamic caliphate, along the lines of the Islamic State group in Iraq and Syria. The extremists fly the black and white flag of al-Qaida and have established a strict version of Shariah law, publicly amputating the hands of alleged looters and whipping people for infractions such as smoking cigarettes.

The army claimed on Oct. 17 that it had established a cease-fire with Boko Haram and it was negotiating for the release of the kidnapped schoolgirls. But Boko Haram leader Abubakar Shekau, in a video released last month, denied there was any truce and said the girls had all converted to Islam and been married off to his fighters.