Sharif had reportedly sent the song around on WhatsApp in March, prompting angry demonstrators to burn down his family house.
Sharif may appeal the verdict.
The ruling has grabbed headlines around the world and comes some four years after authorities last handed down the death sentence for blasphemy. The case was similar to that of Sharif.
'Not a usual occurrence'
In the 12 predominantly Muslim states in the north and northwest Nigeria where Sharia is applied, blasphemy against Islam carries a mandatory death penalty. It is rarely imposed.
"It is not a usual occurrence. Sharia courts have sentenced only two people to death on charges of blasphemy since 2001 when Sharia laws were reintroduced in northern Nigeria, says DW's Zaharaddeen Umar.
"Blasphemy in Islam is considered a very big offense and every Muslim knows the consequences. So cases are few and even when a Sharia court issues a death sentence, its execution requires the approval of a governor of a state."
Governors, Umar says, have not assented to similar cases in the past. Often, citizens take matters into their own hands when confronted with such transgressions.
The ruling in the Sharif case has provoked stronger reactions outside of the predominantly Muslim north parts of Nigeria, according to Umar.
Human rights activists in Abuja have been among the most vocal on social media.
Nigeria's federal government has a long-standing reputation for not making its opinions known on controversial religious issues, says Umar. "President Muhammadu Buhari is no exception. Nothing tangible was heard from him in 2016 when another young man in Kano was sentenced to death for a song considered to be blasphemous."
A tweet by Buhari's personal assistant, Bashir Ahmad, dated June 2015, was being retweeted in the wake of the Sharif sentencing. In it, Ahmad wrote: "I can't pretend or keep silent. I support the death penalty."
An atheist on Facebook
Human rights activists are calling on the government to look into what they say is the illegal detention of a young atheist accused of blasphemy in April.
Mubarak Bala was arrested at his home in Kaduna State and handed over to police in Kano State in early May after a group of Muslim lawyers accused him of insulting the Prophet Mohammed on his Facebook page.
A source within the Justice Ministry confirmed the case to DW, but authorities have declined to comment.
"Regardless of the offense or the sensitivity of the case, the authorities may not withhold information on Bala's whereabouts from people legally," Anietie Ewang of Human Rights Watch says.
Bala and his wife have a newborn baby. Her repeated calls to the Kano State police commissioner to inquire about his whereabouts have gone unanswered.
Angry young Muslims
The Nigeria chapter of HRW has repeatedly urged authorities to ensure that Bala has regular and adequate access to his legal counsel and his family.
Initially, the case against the singer Sharif drew a strong local public reaction. Angry youths calling for justice torched his home. The public reaction to the sentencing — after a trial that lasted four months — ranged from muted to supportive over the outcome in the Sharif case, observers say.
"The young guys who usually react to this kind of situation are not organized. They are not acting based on religious grounds, but they're thinking that people who make blasphemous statements against Islam should be punished," says DW's Zaharaddeen Umar.
Kano-based Human rights activist Zainab Nasir told DW that while she has no objection to his arrest, keeping Bala in detention incommunicado is not in order.
Few see the situation of blasphemy differently. Sani Aliyu, a young graduate in Kano, told DW he considers Bala's lengthy detention illegal and a violation of his fundamental rights. His arrest and detention, according to Aliyu, is no solution to the proliferation of atheism in Nigeria.
COVID-19 related court delay
Islamic scholars like Sherif Almuhajir, a cleric and a lecturer at the Department of Sharia in Yobe state University, have also weighed in. Almuhajir told DW that is not in the teaching of Islam to attack someone who has a different view.
"Nigeria is a multicultural and multidimensional setting. We want other people to come and accept Islam. I don't know how we can convince them to come and be Muslims. Nobody is created by God to die," he told DW.
Religious philosophy researcher, Aliyu Dahiru Aliyu expressed dismay over Bala's detention. COVID-19 lockdown measures may, however, have something to do with the nature of it, he suggests.
"Nigeria is a secular country. Blasphemy is not a crime unless it causes a breach of the peace or incites conflicts, which is punishable with a maximum of two years in prison. He [Mubarak Bala] still has a chance to appeal," Aliyu told DW.
Bala's lawyers filed a case at the Federal High Court in Abuja in May. The case is being delayed due to COVID-19 restrictions on the court. The lawyers are challenging Bala's arrest and detention as a violation of his rights to liberty, fair trial, freedom of thought and expression, and freedom of movement, as enshrined in the Nigerian Constitution and international human rights law.