By Gavin Hewitt
BBC News, Basra
In Britain's past, foreign occupations and outposts of empire have ended with a bugle and a simple ceremony.
It was that way on Thursday in the searing heat of Basra.
Britain is pulling its troops out of Iraq a month ahead of schedule
The lowering of the regimental flag of the 20th Armoured Brigade signalled an end to all British combat operations.
The remaining task for Britain's forces is to pack and return home.
This most controversial of conflicts ended in a corner of the Basra airbase surrounded by concrete blast-proof walls.
"There are still people out there who would like to kill us," Col Richard Stanford had reminded us.
As the temperature soared into the upper 40s, a British flag party marched forward and lowered and folded the flag. Command passed to the Americans.
Their commander praised the British and said: 'We are brothers in arms."
Then Brig Tom Beckett shook hands with Col Henry Kievenaar and, with that handshake, the British mission was over.
Names of dead
There was a brief round of applause - a curious ending to one of the most challenging operations since World War II.
The public at home had grown cool on the conflict. International opinion had been largely hostile.
The enormity of this mission was not to be glimpsed in this transfer of authority, but rather in a moment earlier in the day when hundreds of British forces had filed in front of what had been the brigade's headquarters.
A memorial wall honours those who lost their lives in the UK operation
The chaplain read from the book of Wisdom. "Length of days is not what makes age honourable," he read, "nor numbers of years the true measure of life."
Then, unit by unit, the names of all 179 servicemen and women who died in Iraq were read out. It took 25 minutes.
In the faces of the troops you could glimpse some of the cost of this mission in Iraq; not just the numbers who died but the nearly 1,000 injured.
Some of those present wondered if the prime minister would fly in to mark the end of a six-year mission.
He did not come but John Hutton, the defence secretary, did. He spoke to some troops and climbed inside a Challenger tank.
Afterwards he said: "Yes we paid a very high price. The casualties have been very, very high, but we are coming out of Iraq having done an amazingly good job."
It is the assessment of a politician but it is also the mood of the soldiers.
None sidled up to me and said the conflict had been a waste of lives or an ill-judged adventure.
The view of a tank commander was typical: "It's been very exciting to be part of it and it's nice leaving with that feeling of a job done."
There is a sense of relief for many that their tour of Iraq is ending
Most soldiers believe they have made a difference, and that is enough to return home with heads held high.
There will be an inquiry into the war in Iraq.
Awkward, searching questions will be asked about why Britain went to war, the quality of intelligence used, how the case for war was sold, and the planning for rebuilding the country after invasion.
And then there are the Iraqi lives lost.
The ordinary soldier sidesteps these questions. They are for the politicians, not for them.
And so in the workshops, where they are preparing the tanks for shipping home, the banter is light. For them the heavy hand of Iraq has been lifted.