TL;DR: Up to 21,000 - but we will probably never know the true number.
The last remaining British troops have now withdrawn from Camp Bastion, Helmand province, signalling the end of 13 years of UK involvement in the war in Afghanistan.
While the deaths of the 453 British servicemen and women are well-documented, calculating the large civilian death-toll, not to mention those physically and mentally wounded, is much more difficult.
For the early years of the war - which began in October 2001 - the majority of civilian casualty reports came from the press.
The Guardian reported that as many as 20,000 people could have died as a direct or indirect result of the invasion in the first year of conflict alone, using data from aid agencies. The LA Times, meanwhile, reported that something like 1,201 died in the first year of the conflict, but that excluded unverified reports of many more. Such stark differences in figures highlight the difficulty of verifying this type of data in a war zone.
Later on in the war the United Nations Assistance Mission in Afghanistan (UNAMA) sought to address this problem by collating figures into one central database. All the deaths they record are stringently verified.
UNAMA only reports civilian casualty figures verified through multiple sources. This verification is a rigorous and time-consuming process, which is affected by the security situation.
- United Nations Asssistance Mission in Afghanistan
Their figures, which go back as far as 2007 and end in June 2014, estimate that 11,614 civilians died as a result of the conflict in Afghanistan. However, owing to their rigorous methods of calculation, this figure - which only accounts for just over half the war - is likely to be an underestimate.
The Watson Institute of Brown University in the US, estimates that 21,000 civilians have died as of February this year as part of their Costs of War project.
Ultimately we will probably never know exactly how many civilians died as a result of the conflict or what their names were.
However, when the civilian deaths are added to those of international and Afghan National Army soldiers, it becomes clear that the 13-year operation in Afghanistan came at a huge cost of life.
Yesterday, the Ministry of Defence released the images of all 453 UK servicemen and women who died in Afghanistan.
Every death is a tragedy. But this graphic gives a representation of how many Afghan civilians died at the same time. The black space is indicative of 21,000 civilian deaths, with the UK losses taking up one 45th of the total area in the top right corner.