In a tense trial that was widely seen as a test of religious tolerance in the world's largest Muslim-majority nation, Ahok was "found to have legitimately and convincingly conducted a criminal act of blasphemy, and because of that we have imposed two years of imprisonment", head judge Dwiarso Budi Santiarto told the court.
Jakarta Governor Basuki "Ahok" Tjahaja Purnama, center, is escorted by prosecutors as enters the court room for his sentencing hearing in Jakarta, Indonesia, Tuesday, May 9, 2017.
A man angrily addressing the crowd through a megaphone said, "Brothers and sisters, justice has died in this country".
An edited version of his speech went viral online, sparking outrage.
The Indonesian rupiah extended its decline after the verdict, falling 0.2 per cent to 13,335 against the USA dollar. The legislation was rarely used during the 32-year rule of strongman Suharto, but in recent years has been exploited to persecute minorities, rights groups say.
The protest comes just days before a district court announces its verdict in Gov. Basuki "Ahok" Tjahaja Purnama's blasphemy trial.
Warriors coach Mike Brown cracks up over Lonzo Ball's $500 shoes
He recently released his first shoe from Big Baller Brand, and let's just say, the price was a bit laughable. Mind you, like, no basketball shoes - not LeBrons, not KDs, not Kobes - sell for more than $200.
The Islamist opposition to Ahok started in 2014 when he became the Governor of Jakarta, but intensified with the blasphemy case and subsequent protests.
Purnama, a Christian and member of the country's ethnic Chinese minority, is somewhat of an unusual case in the country in that he is the first non-Muslim leader of Indonesia's sprawling capital, Jakarta, in over 50 years.
"Hard-liners will feel emboldened by the ruling, given that the trial represents a wider tussle between pluralism and Islamism in Indonesia", said Hugo Brennan, an analyst at Verisk Maplecroft, a political risk assessment firm in Singapore. Other anti-Ahok protesters shouted "Allahu Akbar" and "thank you" to the judges, while his supporters, some carrying roses, left in tears.
"I ask that all parties respect the legal process and the verdict that was read by the panel of judges, including respecting steps taken by Basuki Tjahaja Purnama to appeal", Widodo said.
"This decision is the character assassination of a good governor, a clean politician who is rare in this country", he said. The maximum sentence is four years in prison.
In April, prosecutors called for the blasphemy counts to be dropped in exchange for a lesser charge of "spreading hate", but the judges on Tuesday appeared to have ignored that recommendation, reports CNN.