A Washington deputy accidentally shot and killed an off-duty police officer at his home Saturday night after the officer tried to fight off an armed robbery suspect on the run from law enforcement, authorities said.

Vancouver Police Officer Daniel Sahota, 52, was identified as the off-duty officer and homeowner killed, the department announced Sunday.

MILWAUKEE OFFICER'S SHOOTING SUSPECT CHARGED, HELD ON $1M CASH BAIL, COURT RECORDS SHOW

Clark County sheriff’s deputies were responding around 8:15 p.m. to an armed robbery at a convenience store in the Orchards area when the suspect fled in a stolen vehicle, the Clark County Sheriff’s Office said.

Vancouver Police Officer Donald Sahota was killed while off duty at his home on Saturday after deputies mistook him for a robbery suspect, according to investigators. (Vancouver Police Department)

The suspect, who was described as having a handgun, traveled toward Battle Ground, Washington, where he abandoned the vehicle during a police chase and fled on foot, according to authorities. 

The suspect reached the home of Sahota, who armed himself and left his home to try and detain the suspect. But the off-duty officer and the suspect became engaged in a scuffle, FOX12 Oregon reported, citing authorities.

During the fight, investigators said Sahota lost control of his firearm and suffered several stab wounds. The suspect then ran toward Sahota’s home, where his wife was on the phone with 911 inside.

TEXAS SUSPECT CHARGED WITH ATTEMPTED CAPITAL MURDER AFTER ALLEGEDLY SHOOTING THREE HOUSTON POLICE OFFICERS

As Sahota recovered his firearm and chased after the suspect, Clark County deputies arrived at the scene. A deputy opened fire and struck Sahota before realizing he was the homeowner and not the alleged robbery suspect, KGW-TV reported, citing investigators. 

Sahota collapsed on his front porch and was immediately given medical aid, authorities said. He died at the scene. 

The suspect, who has not been named, was taken into custody. Investigators have not released the name of the deputy who discharged his weapon.

"My heart goes out to Officer Sahota’s family and friends and those of us in his VPD family as well," Vancouver Police Chief James McElvain said in a statement. "His death is a tragic loss, and he will be deeply missed by many." 

CLICK HERE TO GET THE FOX NEWS APP

Sahota joined the Vancouver Police Department in 2014, having previously served with the Gresham Police Department and Port of Portland Police Department.

He is survived by his wife and two children.

The Lower Columbia Major Crimes Team is continuing to investigate the incident.