With Gaza largely in ruins after more than 10 months of war, the Hamas-run territory's health ministry has struggled to count the death toll, which on Thursday surpassed 40,000.
Israel has repeatedly questioned the credibility of the daily figures put out by the ministry and US President Joe Biden did so too in the early stages of the war.
But several United Nations agencies that operate in Gaza have said the figures are credible and they are frequently cited by international organisations.
Data collection
Two AFP correspondents witnessed health facilities enter deaths in the ministry's database.
Gaza health officials first identify bodies by visual recognition from a relative or friend, or by recovering personal items.
The deceased's details, including name, gender, birth date and ID number, are then entered in the health ministry's digital database.
If bodies are unrecognisable or unclaimed, staff record the death under a number, noting all available information.
Any distinguishing marks that may help with later identification, whether personal items or a birthmark, are collected and photographed.
Central registry
Gaza's health ministry has outlined its procedures for compiling the death toll.
In public hospitals under the direct supervision of the territory's Hamas government, the "personal information and identity number" of every Palestinian killed during the war are entered in the hospital's database as soon as they are pronounced dead.
The data is then sent to the ministry's central registry on a daily basis.
For deaths in private hospitals and clinics, information is recorded on a form that must be sent to the ministry within 24 hours to be included in the central registry, a ministry statement said.
The ministry's "information centre" then verifies the entries to "ensure they do not contain any duplicates or mistakes", before saving them in the database, the statement added.
Gaza residents are also encouraged by Palestinian authorities to report any deaths in their families on a designated government website. The data is used for the ministry's verifications.
The ministry is staffed with civil servants who answer to the West Bank-based Palestinian Authority as well as to the Hamas government in Gaza.
'High correlation'
An investigation conducted by Airwars, an NGO focused on the impact of war on civilians, analysed the data entries for 3,000 of the dead and found "a high correlation" between the ministry's data and what Palestinian civilians reported online, with 75 per cent of publicly reported names also appearing on the ministry's list.
The study found that the ministry's figures had become "less accurate" as the war dragged on, a development it attributed to the heavy damage to health infrastructure resulting from the war.
For instance, at southern Gaza's Nasser Hospital, one of the few still at least partly functioning, only 50 out of 400 computers still work, its director Atef al-Hout told AFP.
Israeli authorities frequently criticise the ministry's figures for failing to distinguish between combatants and civilians. But neither the army nor Israeli Prime Minister Benjamin Netanyahu deny the scale of the overall toll.
The press office of Gaza's Hamas government had previously estimated that nearly 70 per cent of the roughly 40,000 dead are women (about 11,000) or children (at least 16,300).
Several UN agencies, including the agency in charge of Palestinian refugees (UNRWA), have said the ministry's figures are credible.
"In the past - the five, six cycles of conflict in the Gaza Strip - these figures were considered as credible and no one ever really challenged these figures," the agency's chief Philippe Lazzarini said in October.
In a letter published by British medical review The Lancet in July, a group of researchers estimated that 186,000 or more deaths could eventually be attributed to the war in Gaza, based on statistical projections using the Ministry of Health figures. Their estimate would include not only those killed directly by the fighting, but also deaths as a result of the humanitarian crisis triggered by the war.
The war in Gaza was triggered by Hamas's October 7 attack on Israel, which resulted in the deaths of 1,198 people, mostly civilians, according to an AFP tally based on Israeli official figures.