Gunmen in the southern Mexican state of Oaxaca shot and killed Hamurabi Huesca Manzano, the owner of a local news website who also drove a taxi, on Friday, making him the ninth journalist killed in Mexico this year, according to the press freedom group Article 19.

Mr. Huesca ran Pinotepa Comunica, a digital outlet covering Santiago Pinotepa Nacional and nearby towns on the Oaxaca coast that had more than 50,000 followers. An armed group opened fire on him and two other people, according to the state prosecutor’s report, Al Jazeera reported, drawing on Agence France-Presse.

Prosecutors say the gunmen were after someone else. Their main line of investigation is a fight between local criminal groups, and they named the target as a reputed crime boss known as “El Darío,” identified only by the initials D.A.S.A., who was known for stirring up violence on the coast. Mr. Huesca had been called to give him a ride and was waiting in his taxi when the shooting started, prosecutors said.

Mr. Huesca and a third man, identified as O.F.M.M., died at the scene. El Darío was wounded and died hours later at a regional hospital, Proceso reported.

Prosecutors said the attackers were “fully identified.” They didn’t name them, and no arrests had been reported by Saturday. Nor did they say whether Mr. Huesca’s journalism played any part, though they haven’t ruled it out.

The local accounts don’t line up. Several Mexican outlets, among them ADN40, reported that he was attacked at his home and that a woman was wounded and taken for treatment. Police reports cited in the Mexican press put the shooting inside a house in the La Planta neighborhood. The prosecutor’s version mentions no wounded woman. It was not clear which account was right.

Article 19 pressed the authorities on that point in a post on X. “We demand that the prosecutor’s office treat his journalistic work as a priority in its investigation,” the group wrote.

Antonio Olmedo Mendoza, the mayor of San Miguel Tlacamama, confirmed the death and offered his condolences. “With deep sorrow, I regret the passing of Hamurabi Sinclair Huesca Manzano,” he said.

Reporters and editors in the region condemned the killing and called for the people responsible to be punished, El Universal reported.

Mexico is one of the deadliest countries in the world for the press. Reporters Without Borders counts more than 150 media workers killed there since 1994.

Mr. Huesca is the second journalist killed in Oaxaca in less than three months, according to Mexican news reports. On July 22, Francisco Alejandro Leyva Aguilar was shot dead at a food stand in San Pablo Etla. No one has been charged in that case.