CNN  — 

Massacred by militants. Starved to death. Killed while trying to escape.

These were common scenes experienced by Mosul’s residents under nearly three years of ISIS rule. But Sunday, Iraqi forces declared the city free from the grip of ISIS and its regime of terror.

Iraqi Prime Minister Haider al-Abadi arrived in what he described as the “liberated city of Mosul” on Sunday and congratulated “the heroic fighters and the Iraqi people in achieving this great victory.”

And yet, skepticism remained with state TV reporting that ISIS militants were still holding out in one neighborhood of the city.

While the Iraqi-led coalition is expected to eventually defeat ISIS in the region, the suffering that the terror group has inflicted on Mosul’s residents has left a lasting scar on the city and its people.

The city's remaining civilians have endured three years of terror.

ISIS in the shadows

Mosul remains a desperate place – with a palpable fear of an ISIS resurgence at the forefront of many minds.

At the start of the offensive, it was believed that around 3,500 to 5,000 ISIS fighters were in Mosul, according to US military officials. ISIS supporters placed the numbers at around 7,000. That figure had dwindled to a couple hundred before the city fell, according to the coalition.

The militant group commonly deployed terror tactics against the encroaching coalition – using suicide bombs, IED booby traps and car bombs to fight against Iraqi forces. Many fighters used civilians as human shields, ducking behind the innocent before maneuvering through Mosul’s bombed out Old City, which had become a labyrinth of elaborate underground tunnels and trenches.

Watch: Can ISIS ever be eradicated?

An Iraqi special forces humvee rides through the Old City on June 29.

Civilian casualties

Across the country, more than 1,535 strikes targeting ISIS militants have been conducted by the coalition since the start of the offensive in October, according to a spokesperson from the US-led Operation Inherent Resolve. Many of them have specifically targeted Mosul and nearby towns in the surrounding Nineveh region.

In March, a senior Iraqi military officer said a coalition airstrike on an explosives-laden ISIS truck led to the deaths of dozens of civilians.

At least 112 bodies were pulled from the site of that strike. Their deaths reignited concerns about the civilian cost of coalition airstrikes and prompted the US military to launch a formal investigation into the airstrikes, which continue to target ISIS in other parts of Iraq and in neighboring Syria.

Some risked their lives to flee the violence but were targeted by ISIS militants during the escape. Others who managed to get out might soon return to unknowable pieces of rubble.

As Mosul sheds itself from ISIS’s oppressive cloak, its people face the long, arduous task of rebuilding what’s left of their lives.

A skeletal population

Iraq’s second largest city was once a bustling trading hub. Now, it’s almost unrecognizable. Before ISIS seized control, Mosul was home to 2.5 million people. Hundreds of thousands fled as the extremists began to enforce their violent rule, which included public beheadings and the enforcement of sharia law.

That number has risen dramatically in the years that followed, culminating in a daily mass exodus of around 10,000 people in recent months, according to UN estimates.

Since the coalition-led offensive to regain control of the city began in October, more than 860,000 people have fled from their homes, according to the World Health Organization, with hundreds of thousands of people now living in refugee camps for the internally displaced or outside Iraq altogether.

Eastern Mosul fell in January before a second phase, aimed at clearing ISIS militants from the western part of the city, launched in February. The coalition’s final push brought fighting that pushed 566,000 people from western Mosul out of the city in just four months.