Marysville police identified the officer as Derek Carlile, a 3-year veteran of the department.
The 7-year-old girl was shot by her brother, who found the loaded gun in the glove compartment of the family's van as it was parked near the Stanwood City Hall.
Investigators said the boy was handling the weapon when the gun discharged, striking the girl. Jenna Carlile died Sunday at Harborview Medical Center in Seattle.
The parents were out of the vehicle at the time of the shooting, but nearby.
It was not known whether the gun was the officer's duty weapon or a personal firearm. The age of the boy who pulled the trigger was not released.
"I can tell you as a police chief, this is one of the most difficult things I have ever been apart of," said Marysville Police Chief Rick Smith. "One thing you don't want to see is your officer's children get hurt. And it falls along the same lines of an officer being hurt or killed."
The police chief said the department is grieving along with the officer's family.
"It is tragic," Smith said. "It's extremely difficult. It's difficult for us as a department. We are rallying around, because that's what we do and we try to do the best that we can. Everything that needs to be done will be done."
Jenna was a student at Utsalady Elementary School on Camano Island. Grief counselors were on hand on Monday to help students cope with the tragedy.