The Taliban have vowed to disrupt the vote and have stepped up violence in recent weeks, including increased attacks on civilian targets in Kabul and the killings of a Swedish journalist and an Afghan journalist for the French news agency Agence France-Presse.
Karzai said in a statement that he "grieved" Niedringhaus' death and wished a quick recovery for Gannon. He also ordered an investigation into the shooting.
In a memo to staff, AP President Gary Pruitt remembered Niedringhaus as "spirited, intrepid and fearless, with a raucous laugh that we will always remember."
"Anja is the 32nd AP staffer to give their life in pursuit of the news since AP was founded in 1846," he wrote. "This is a profession of the brave and the passionate, those committed to the mission of bringing to the world information that is fair, accurate and important. Anja Niedringhaus met that definition in every way."
Niedringhaus joined the AP in 2002, and while based in Geneva worked throughout the Middle East as well as Afghanistan and Pakistan. In 2005, she was part of the AP team that won the Pulitzer Prize for breaking news photography for coverage of Iraq, and was awarded the Courage in Journalism Award from the International Women's Media Foundation, among many journalistic honors. In 2006-07, she studied at Harvard University under a Nieman Fellowship.
"What the world knows about Iraq, they largely know because of her pictures and the pictures by the photographers she raised and beat into shape," said AP photographer David Guttenfelder. "I know they always ask themselves, 'What would Anja do?' when they go out with their cameras. I think we all do."
"She truly believed in the need to bear witness," said Santiago Lyon, AP vice president and director of photography.
Niedringhaus captured what war meant to her subjects: an Afghan boy on a swing holding a toy submachine gun, a black-clad Iraqi giving a bottle to her baby as she waits for prisoners to be released, a U.S. Marine mourning the loss of 31 comrades.