Iraqi security forces hold an Iraqi flag with an Islamic State flag they had pulled down at a government complex in the city of Ramadi, Dec. 28, 2015. Reuters

Iraqi forces were still battling Islamic State group fighters on Monday in pockets of Ramadi, hours after the country's prime minister, Haider al-Abadi, announced victory in liberating the city. This victory is groundwork for a long-term campaign to retake territory from the extremist Islamic State group, also known as ISIS or ISIL, which had seized large swaths of Iraq and Syria in the last year and a half.

To prove its ability to defeat ISIS, the Iraqi government will have to continue retaking areas seized by the militant group, such as Mosul. Hundreds of ISIS fighters were believed to have fought the Iraqi military in Ramadi and thousands more are stationed in Mosul, which has become ISIS' major hub in Iraq. At the same time, Mosul's political landscape, with few Sunni tribal allies on the ground and a limited Iraqi military presence nearby, could make battle there more difficult, if not impossible, analysts said.

“The decisive victory will be defeating these guys in a major area and taking Raqqa or Mosul," said James Jeffrey, a former U.S. ambassador to Iraq (2010 to 2012) and a fellow at the Washington Institute for Near East Policy. “[Ramadi] has taken a long time, it's not over yet and ISIS didn't put a whole lot of forces into Ramadi ... Ramadi is a success, but time is not on our side.”

The recapture of Ramadi, the capital of Iraq’s Anbar province, has been hailed as the most significant event in a string of recent victories against the Islamic State group. As of Monday morning, however, militants continued to resist in as much as 30 percent of the city, according to the New York Times.

The capture of Mosul by ISIS last year was seen to mark a major inroad for the militant group into Iraq. Iraqi soldiers dropped their weapons and fled at ISIS' advance, as militants seized large caches of American-made weapons and vehicles. The northern Iraqi, predominantly-Sunni city has become a base for the militant group and retaking it has become a key goal for the Iraqi military.

In recent months, the tides have turned against ISIS. The extremist group has lost considerable hold on its territory to Iraqi and Kurdish forces, Shiite militias and Sunni tribes. A U.S.-led airstrike campaign has helped back the Iraqi government and Kurdish forces in Iraq and has also focused on cutting off the militant group's revenue sources in both Iraq and Syria.

Iraqi Security Forces are preparing to retake Mosul from ISIS, but are struggling to secure a full-fledged Sunni force necessary for battle in the northern city. REUTERS/Ahmed Jadallah

With the victory in Ramadi, Abadi has again vowed to set his sights on Mosul. In the past, he has said he would focus on retaking Mosul by the end of 2015, but that goal seems to have failed as 2016 approaches.

“The liberation of dear Mosul will be achieved with the cooperation and unity of all Iraqis after the victory in Ramadi,” Abadi said in a statement last week, as Iraqi forces were making gains against ISIS.

But actually retaking the city could be difficult. Unlike the Anbar province, where Sunni tribes have fought alongside Iraqi forces, Sunni factions -- long alienated from the Shiite-dominated government in Baghdad -- do not seem as capable in Mosul. The most formidable force near Mosul are Kurdish factions and they have largely been disinterested in fighting.

Iraq mosul
A member of the Iraqi security forces holds an Iraqi flag at a government complex in the city of Ramadi, Dec. 28, 2015. REUTERS/Stringer

“[ISIS] will use a lot more force [in Mosul] -- that’s where the caliphate was announced and they’ll fight hard for it,” Jeffrey said. “You don’t have the obvious forces you have to fight [with in Mosul] that you have in Anbar … you have a divided political situation.”

While many agree that retaking Mosul is crucial to defeating – or at least weakening – ISIS in Iraq, it might not be possible in the near future, according to Ben Connable, a senior international policy analyst at the Washington-based RAND Corporation. The further Iraq's military extends its reach, the more its grip is likely to loosen on areas already held, he said.

“It is the crown jewel of the ISIS terrain in Iraq. It’s hugely symbolic, but it’s also strategic – so Mosul matters a lot,” he said. “But if the plan is to move on to Mosul, you would assume the [counter terrorism forces] would be shifted out of Ramadi … and who’s going to stabilize the city? Who’s going to prevent the Islamic State from moving back in?”

Iraq's Shi'ite paramilitaries launch a mortar toward Islamic State militants at North of Fallujah in province of Anbar, July 6, 2015. REUTERS/Stringer

For now, the next battle is likely to be Fallujah, another major city east of Ramadi and about 40 miles outside of the Iraqi capital Baghdad. Iraqi forces in recent months have focused on taking back control of the Anbar province before moving north to Mosul, as retaking that strategic city will be pivotal in proving they are capable of securing long-term stability and uniting the country, analysts said.

“Mosul is the ultimate test,” Connable said.