The officer was hospitalized and was expected to survive, Los Angeles Police Chief Michel Moore tweeted.
"The officer involved in this incident was transported to a local hospital and is receiving medical attention for non-life-threatening injuries," LAPD wrote on Twitter. "The suspect involved in this incident is in custody. This is preliminary information, as this is an active and ongoing investigation."
Moore said the officer suffered "bumps and bruises" but wasn't shot. He said he had spoken to the officer who was in stable condition at the hospital. He didn't say how serious the officer's injuries were.
"He is resting and will be ok...Harbor units responding pursued suspect and took him into custody," Moore wrote on Twitter.
Moore told reporters the suspect, who was a man approximately 29 years old, walked into the lobby of the station and the officer went out to talk to him.
"It escalated into some type of altercation. During that altercation, it appears at this very early stage that the officer's weapon was taken from him and rounds were fired by the individual at the officer," he said in an early Sunday morning press conference outside of the hospital where the officer was being treated.
The watch commander on duty saw the suspect hitting the officer in the station and grab the officer's gun, Assistant Police Chief Horace Frank told The Los Angeles Times. He said the watch commander fired at the suspect who ran and drove away.
Previous reporting said the officer had been shot in the head.
The incident happened shortly before 10 p.m. PT, KABC-TV in Los Angeles reported.
Bill Melugin of FOX 11 in Los Angeles reported the suspect had been pistol-whipping the officer after grabbing his gun.
"Sending my best wishes for a quick and full recovery to our @LAPDHQ officer injured in an incident at the Harbor Station tonight," Los Angeles Mayor Eric Garcetti tweeted early Sunday. "The officer is in stable condition and we're closely monitoring the situation."
In a separate incident early Saturday morning, a suspect driving a black SUV shot at an off-duty LAPD officer in Reseda, about 40 miles north of San Pedro. The suspect missed the officer but hit his car, KNBC-TV reported.
The Saturday incidents came exactly two weeks after two Los Angeles County Sheriff’s deputies were shot in the head in an "ambush" attack while sitting in a patrol car near a Compton Metro station. Both deputies underwent surgery and are recovering at home after being released from the hospital.