A man was shot and killed Thursday after he pointed a handgun at Los Angeles County sheriff’s deputies, authorities said.

The man was shot shortly after 5:30 a.m. in the Los Angeles suburb of Maywood, the Sheriff's Department said in a statement.

Detectives with an anti-gang unit were serving a search warrant at a home when a man inside became "verbally aggressive," got a gun and told deputies standing outside to get away from the residence, the department said.

OR POLICE FATALLY SHOOTS MAN SUSPECTED IN ARMED ROBBERY, CARJACKING

LA, CA, crime

A man wielding a gun at Los Angeles deputies was fatally shot several times Thursday morning. (Fox News)

"Deputies attempted to de-escalate the situation by explaining to him that he was not the focus of their presence at the location," the statement said.

The man went to an open side door, holding the gun pointed toward the ceiling, then he walked to the threshold and pointed the gun at deputies, authorities said.

CLICK HERE TO GET THE FOX NEWS APP

He was shot several times and died at the scene. His name wasn't immediately released.

Other details of the confrontation weren't immediately released.

A loaded gun was recovered at the scene, authorities said.