This is the moment that a cop bravely pursued a gunman through a Costco before shooting him dead while others fled the store.

Captain Michael Howell was on his day off when he saw the gunman burst into the store with a pistol in in Lenexa, Kansas, and begin screaming 'I'm going to kill people'.

But as gunman Roland Hunt made his way further into the store, Captain Howell was in hot pursuit with his gun drawn on Sunday.

The cop, who has worked for the Kansas City Police Department police for 22 years, can be seen stealthily trailing the man in the video.

Captain Michael Howell had been in Costco with a friend on his day off, looking for an electric fireplace

He later shot the gunman dead when 58-year-old Hunt turned his revolver on the officer.

Neither Howell or any other customer was hurt.

The gunman had been a long-haul truck driver, was living in his truck in the car park of the Costco before he walked into the store brandishing the gun.

Captain Howell was modest about his heroism: 'I'm just a cop doing my job.'

'My greatest fear was we had kids with their moms, with their grandmas, with their dads,' Howell said, according to Police One.

'It was little kids running and screaming. And seeing the fear in their faces and knowing whatever it took, I had to do whatever necessary to end this threat so they wouldn't get hurt.'

The footage shows a Costco employee drop to the floor when the gunman points his gun in their direction

Captain Michael Howell was on his day off when he saw the Ronald Hunt, 58, moving through the store with a gun

The video shows Hunt walking in the store, then pointing his gun at a Costco employee, who drops to the floor.

The footage then cuts to customers fleeing the shop floor, before Howell can be seen stealthily tracking the gunman.

Howell also described what happened when he saw the gunman. 'I could see a white male, looked kind of disheveled, wearing a camo jacket, waving a large revolver, looked like about 10 or 12 inches long, pushing a grocery cart and not looking at anybody.

The police captain, who has worked for the Kansas City Police Department police for 22 years, can be seen stealthily trailing the man in the video

The gunman, Hunt, reportedly said 'I'm an off-duty U.S. marshal and I'm here to kill people' as he moved through the store with his revolver

'But I heard him say three different times, "I'm an off-duty U.S. marshal and I'm here to kill people."' reported KMBC 9.

He added that he knew he had to use the element of surprise as he was not wearing his bulletproof vest.

Authorities do not believe Hunt had a specific target in mind when he walked into the store with a gun, which he never fired.

Captain Howell had been in the store with a friend, looking for a new electric fireplace.

Police One report that Johnson County District Attorney Steve Howe said the police captain had 'acted with extreme courage, and saved an unknown amount of innocent lives.'