For three years, Islamic State militants controlled the Syrian border city of Jarabulus, transforming a once-tranquil place on the banks of the Euphrates River into a way station for jihadis who posed for photos at the border crossing from Turkey.
That ended Wednesday, when hundreds of Syrian rebel fighters backed by the United States and Turkey stormed the city, officials and activists said, ousting the militant group while also keeping Syrian Kurdish militias, Ankara's archfoes, from establishing a foothold in the area.
Turkish artillery pounded Islamic State positions in Jarabulus, about 60 miles northeast of the city of Aleppo and less than two miles from the Turkish border while Turkish and U.S. F-16s hit Islamic State targets from the air.
The U.S. also deployed A-10 attack planes and armed drones, and U.S. special forces advisors worked alongside Turkish commanders in Turkey, according to U.S. officials who spoke on condition of anonymity because the offensive was still underway.
The loss of Jarabulus marked the end of Islamic State's presence along the 500-mile Syria-Turkey border. U.S. officials estimated that there had been 200 to 300 Islamic State fighters in the city.
Over the last five years, Turkey has provided vital support for the opposition, giving its fighters weapons and intelligence to mount operations against the Syrian government. In the past, it also turned a blind eye to militants, including those from Islamic State, arriving from abroad, who were then smuggled across the Turkish border into Syria to fight forces loyal to Syrian President Bashar Assad.
Yet Wednesday's offensive marked the first time Ankara had openly fought alongside rebel insurgents on Syrian soil. It was also a fulfillment of Turkish Prime Minister Binali Yildirim's vow last week that his nation would play "a more active role" in the conflict, with the aim of preventing Syria's partition "along ethnic lines" — a veiled reference to Syria's Kurds.
The barrage, which began at 4 a.m., preceded a wide-scale offensive that saw dozens of Turkish tanks and armored vehicles cross into Syrian territory even as special forces units cleared the path for Syrian rebels — operating under the banner of the Free Syrian Army — to overrun the area.
The offensive, dubbed "Euphrates Shield," was intended to "strengthen Turkey's border security by clearing away terrorist groups, and support Syria's territorial integrity," according to a report by Turkey's state news agency Anadolu. Turkish President Recep Tayyep Erdogan said the assault was a response to terrorist attacks in southern Turkey in recent months — in particular, a suicide attack on a wedding in the city of Gaziantep on Saturday that claimed 54 lives.
"Right now, unfortunately, all the attacks which happened in Gaziantep … brought this issue to this point," Erdogan told an audience at the presidential palace in Ankara. "Turkey's patience has run out…. This is the end. We said it needed to be finished and the process has started this morning at 4 a.m. We have to solve the problem."
"Jarabulus is completely liberated, and the Free Syrian Army is now combing the area for any remaining Islamic State presence," said Mahmoud Ali, head of the pro-opposition Jarabulus Local Council, in a phone interview.
He added that the rebels had reached areas roughly six miles south of Jarabulus in their pursuit of the militants. The Sultan Murad Brigade, one of the rebel groups participating in the offensive, announced on its Facebook page that it had taken the city.
Abdul-Rahman Ali, another member of the Jarabulus Local Council, sent a video showing rebel fighters sitting on the sidewalk of a major thoroughfare in the middle of the city.
Ali added that the rebels had also taken a string of surrounding villages. The Associated Press and the Anadolu news agency both reported that Syrian rebels had captured the village of Kaklijah, about two miles south of the Turkish border near Jarabulus.
Anadolu reported that one Free Syrian Army rebel was killed and that 10 others were being treated in Turkey for wounds. Turkish and coalition jets took a heavy toll on Islamic State reinforcements coming from the Islamic State-held city of Al Bab, 40 miles southwest of Jarabulus, local media reported.
An unidentified source in the Syrian Foreign Ministry condemned the Turkish incursion, according to the official Syrian Arab News Agency, describing it as a "blatant violation" of Syrian sovereignty.
"Fighting terrorism does not happen in the expulsion of Daesh and replacing it with terrorist organizations directly supported by Turkey," said the source, referring to Islamic State by its Arabic acronym. Damascus categorizes all rebel factions fighting the Assad government as terrorists.
The news agency also quoted a statement from Russia, Assad's strongest ally, urging Ankara to coordinate with Damascus in the fight against terrorism.
Jarabulus was once best known as the home of an archaeological site excavated by T.E. Lawrence — known as Lawrence of Arabia. It was taken over by Islamic State in 2013.
The militants' presence was tolerated by a Turkish government that saw them as a powerful deterrent to the increasing power of Syria's Kurdish political party, the Democratic Union Party, and the Syrian Kurdish militia, the People's Protection Units, or YPG.
Ankara considers the Democratic Union Party to be the Syrian offshoot of Turkey's outlawed Kurdistan Workers Party, or PKK, which it has battled for decades. It says the Syrian party aims to create an autonomous Kurdish entity on Syrian soil, which would encourage Turkey's large Kurdish population to seek separation as well.
This month, the Democratic Union Party — which the U.S. has bolsteredas its primary anti-Islamic State ground force in Syria — joined forces with other rebel groups to rout Islamic State from Manbij, 20 miles south of Jarabulus.
The U.S. touted the operation as a success, but Ankara saw it as another step toward the linking of Kurdish-controlled areas along the Syrian-Turkish border. Kurds hold sway over a 170-mile swath of land extending from Syria's northeastern tip to the town of Kobani as well as part of Aleppo province.
After that victory, the Kurdish forces set their sights on Jarabulus, prompting Ankara to try to preempt the Kurdish assault with its own campaign.
"Jarabulus was expected to fall soon anyway and … the Kurds would move in to take it," said Gareth Jenkins, an Istanbul-based security analyst. "The [Turkish] offensive is a way to drive a wedge between the two Kurdish-controlled areas."
It also puts the U.S. in the position of supporting two rival forces.
At a news conference in Ankara, Vice President Joe Biden appeared to side with Turkey and threatened to cut all support to the Democratic Union Party if its militiamen did not withdraw to areas east of the Euphrates.
Yet at a news briefing in Washington, White House Press Secretary Josh Earnest said the crux of U.S. strategy was to support local forces in Syria that are committed to fighting Islamic State.
"The fact is there have been diverse forces inside of Syria that, yes, that include some Kurds…. And we're going to continue to support those … forces," he said.
Bulos is a special correspondent. Times staff writer W.J. Hennigan in Washington and special correspondent Umar Farooq in Istanbul, Turkey, contributed to this report.
3:30 p.m.: Updates with background, comments from the White House and Vice President Joe Biden and other details.
11:50 a.m.: This article was updated throughout with additional details about Islamic State's loss of the city of Jarabulus to Syrian rebel fighters.