Among the Nigerians still held captive are scores of Chibok girls who Boko Haram kidnapped about a year before Mr Buhari was elected.
President Muhammadu Buhari has expressed grief that his administration could not secure freedom for Nigerians kidnapped by armed groups.
Mr Buhari stated this in his farewell address to Nigerians on Sunday.
"Up-till now, I still grieve for our children still in captivity, mourn with parents, friends and relatives of all those that lost loved ones in the days of the senseless brigandage and carnage," the Nigerian leader said.
Among the Nigerians still held by their abductors are scores of Chibok girls who Boko Haram kidnapped about a year before Mr Buhari assumed office.
"For all those under unlawful captivity, our Security Agencies are working round the clock to secure their release unharmed," Mr Buhari said.
The girls -nearly 300 - were abducted by the extremist sect Boko Haram on 14 April 2014, from a government girls' secondary school in Chibok.
Some abducted girls escaped and were rescued by the Nigerian security forces, while others remain missing.
Boko Haram released a batch of 21 girls on 13 October 2016 after intense negotiation with the Nigerian government. The Red Cross and the Swiss government facilitated the negotiations.
Since the Chibok abduction happened in the North-east Borno State, terrorist groups across Northern Nigeria have continued targeting public schools and abducting school children for ransom.
The following are some of the notable school abductions during the administration of Mr Buhari.
Yobe State
In February 2018, Boko Haram attacked Dapchi and kidnapped 109 girls from the Government Girls Science and Technical College in the town. Though the girls were later released, one of them, Leah Sharibu, was denied freedom after she reportedly refused to renounce Christianity and be converted to Islam.
Katsina State
In December 2020, Boko Haram, who had mainly operated in the North-east region, surprisingly claimed responsibility for the abduction of over 300 pupils of the Government Science Secondary School in Kankara, Katsina State.
Six days after the abduction, the Islamist group released a video that showed some boys abducted from the school pleading for a safe return home.
The Katsina State government later announced that the school boys had been released after negotiating with the terrorists. The government, however, did not disclose the terms of the negotiation. President Buhari, who was holidaying at his Daura home when the incident happened, addressed the released children at the Katsina Government House.
Niger State
On 17 February 2021, terrorists abducted pupils of the Government Science School, Kagara, in Niger State. The terrorists, who wore military fatigue, attacked the boarding school after overpowering the security guards.
The pupils were later released. Three months after the Kagara attack, which is the council headquarters of Rafi Local Government, the terrorists also launched an attack on the second most populous community in the council area, Tegina, and abducted 136 pupils from the Salihu Tanko Islamiyya School on 30 May.
Some of the students were released a day after they were taken. A few of them escaped from their abductors, while 90 of them were released on 26 August after their parents paid a ransom of N60 million and five motorcycles.
Zamfara State
Before the Tegina incident in Niger state, at least 317 schoolgirls were abducted by the terrorists on 26 February 2021 at the Government Girls Secondary School, Jangebe, Talata Mafara Local Government, Zamfara State.
The terrorists raided the school, shooting into the air for over two hours before abducting the female students into a nearby forest.
By then, attacks by terrorists kidnapping schoolchildren were fast becoming a norm in Northern Nigeria, raising fears among Nigerians in rural communities while the government was left with no option but to shut down schools in vulnerable areas.
Kaduna State
On 12 March 2021, 27 students of the Federal College of Forestry Mechanisation, Afaka, Kaduna State, were kidnapped by terrorists. Seven weeks after their abduction, their parents reportedly paid an undisclosed ransom before they were released.
Nigerian Army rescues two more Chibok girls in Borno
Also, in Kaduna, on 21 April 2021, some terrorists attacked Greenfield University, a private university, and kidnapped 17 students.
The Greenfield University, located along the then troubled Kaduna-Abuja highway, was easy prey for the assailants.
The students were later released.
On 11 June 2021, six students and two teachers of the Nuhu Bamalli Polytechnic, Zaria, were kidnapped by the terrorists.
During the operation, the terrorist killed one student, identified as Ali Ali.
Thirty days after the incident, the abductees were freed after they paid an undisclosed amount of money as ransom.
Kebbi State
On 17 June 2021, a terrorist group believed to be led by Dogo Gide abducted more than 100 pupils and some teachers at the Federal Government College Yauri in Birnin-Yauri, Kebbi State.
Many of the girls escaped a few days after their abduction; others were released after a ransom was allegedly paid to the terrorist group.
The terrorists held on to 11 of the girls until the last two were released in May 2023 after paying several instalments of ransom, running into over N100 million.