February 9, 2020 | 9:02pm| Updated February 9, 2020 | 9:03pm

Accused cop-shooter Robert Williams duped an ex-NYPD gal pal into giving him a ride to the Bronx police precinct where he opened fire and wounded a lieutenant Sunday, the woman told The Post.

“I had no clue he was doing this,” said Liza Valdez, 43. “If I knew, I wouldn’t be next to him at that moment. I don’t know what was going on in his head.”

Hours before the Sunday-morning stationhouse shooting, Williams allegedly opened fire on a Bronx cop on East 163rd Street around 8:30 p.m. Saturday.

Valdez, a former NYPD probationary communications technician, said she had no idea about the earlier incident when she met up with Williams.

“We went to have breakfast,” she said. “And he tells me to take him to his mother’s. I know she lives over in that direction.”

“And then he got out of the car and he did what he did,” she said.

Once inside the stationhouse police said Williams opened fire with a 9 mm handgun — striking a lieutenant in the arm.

Valdez was questioned at the 41st Precinct stationhouse after Williams was taken into custody around 8 a.m. She was later released without charges.

Sources told The Post that Valdez was Williams’ girlfriend, but the single mother said they are just “longtime friends” who grew up on the same Bronx block.

Cops would not comment on Valdez, saying that the case remains under investigation.