A crush killed four people and injured dozens as fans tried to get into the stadium hours before kickoff.
Hosts Iraq have won the Arabian Gulf Cup for the first time since 1988 with a 3-2 victory over Oman in the final, an occasion marred by a deadly stampede outside the Basra International Stadium.
A last-minute extra-time goal by Manaf Younis on Thursday was enough to help Iraq lift the tournament for the fourth time.
Earlier, Iraq opened the scoring through midfielder Ibrahim Bayesh in the 24th minute. Salaah al-Yahyaei equalised in stoppage time through a penalty and send the game into extra time.
Amjad Atwan put Iraq back into the lead in the 116th minute. However, in another twist to the game, Oman’s Omar al-Malki scored in the 119th minute to level the score again.
With seconds left, Iraqi centre-back Younis scored the winner.
There were celebrations across the country, with honking car horns and fireworks. In the capital, Baghdad, hundreds of joyous people gathered at Tahrir Square waving their country’s flag.
“We really needed to feel this joy,” said Mansour Zamil, a supporter in Basra, according to AFP news agency.
Long banned from hosting international football matches, war-torn Iraq had been counting on the Gulf Cup to improve its image.
On Thursday, as fans tried to get into the stadium hours before kickoff, a crush killed four people and injured dozens, a health official said.
Thousands of fans without tickets had gathered outside the stadium since dawn in hopes of watching the match.
An AFP photographer inside the stadium said the turnstiles were still closed when the stampede broke out. Sirens blared as ambulances arrived to rush the injured to hospital.
It was a blow for organisers of the first international football tournament hosted in Iraq since 1979 as the bigger prize of hosting the 2026 World Cup qualifiers seemed to be within reach.
Due to security concerns, Iraq has staged only two World Cup qualifiers since the US-led invasion of 2003, against Jordan in the northern city of Erbil in 2011 and Hong Kong in Basra eight years later.
All other competitive games involving the national team have been played in neighbouring countries such as Jordan, Qatar and the United Arab Emirates.
Baghdad last staged a competitive international game in September 2001 against Bahrain. It was scheduled to host a 2022 World Cup qualifier against the UAE on March 24 last year. But following a missile attack on Erbil 11 days before the game, it was shifted to Saudi Arabia.