Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

A violent sex-crimes suspect who was on the FBI's "Ten Most Wanted" list was fatally shot during an attempted arrest at a North Carolina hotel early Wednesday, authorities said.

Greg Alyn Carlson, 46, was killed by an FBI agent at Woodspring Suites in Apex, about 15 miles west of Raleigh, officials said.

Carlson was killed with one shot inside his room, according to John Strong, special agent in charge of the FBI’s Charlotte office.

Greg Alyn Carlson, wanted for his alleged involvement in multiple armed sexual assaults, has been named to the FBI's Ten Most Wanted Fugitives list. FBI

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

The fugitive's car was spotted Tuesday night by an Apex police officer, leading to the hotel raid early Wednesday, according to Strong and Apex Police Chief John Letteney.

“I’m confident that this 'Top Ten Most Wanted' fugitive would still be out in public, amongst us, if it wasn't for that sharp-eyed officer who spotted that vehicle," Strong told reporters outside the hotel where the shooting happened.

The car the Apex officer spotted was the same one listed on Carlson's description on the FBI list — a stolen white, four-door, 2017 Hyundai Accent rental car with a South Carolina license plate, according to Strong.

“The officer last night noticed something suspicious, followed his training and our protocols," Letteney said.

Strong said he regretted that authorities weren't able to capture Carlson alive.

“What happened here today is not what we want to happen. We want to capture the individual, give them their day in court and bring them to justice. What happened today was unfortunate. It’s definitely not what we wanted to happen," Strong said.

"We feel fortunate that no one else was injured. But by no means did we want this to happen to this individual. He deserved his day in court but unfortunately, he didn’t have the opportunity."

Carlson was accused of sexually assaulting a woman and striking her in the head with a gun during a July 13, 2017 burglary in West Los Angeles. He was arrested later that year before he skipped bail.

He had also been linked to other violent sexual assaults around Los Angeles.

Since he was on the run, Carlson had been spotted in Florida, South Carolina and Alabama, where he led police on a high-speed chase in November 2017 before officers called it off over safety concerns.