Fernando Villavicencio, a presidential candidate in Ecuador’s forthcoming elections was shot and killed at his campaign rally on Wednesday.
The representative of the country’s national assembly was attacked as he left the event in the capital, Quito.
Fernando Villavicencio had received threats from a gang calling itself Los Choneros last month and had been given a security detail.
Crime in Ecuador has shot up following the presence of Mexican and Colombian drug cartels recruiting local gangs in the country.
Following his murder, a video appeared on social media in which heavily armed men wearing balaclavas claimed responsibility for the murder. The men claim to belong to Los Lobos (The Wolves), who are rivals of Los Choneros.
Hours later, another video appeared online, this time, a group of men without masks, saying they are the real Los Lobos and they had nothing to do with the murder.
Mr Villavicencio, who was married and had five children, was one of eight candidates in the first round of the election and his focus was on fighting corruption.
Last month, the mayor of the city of Manta was shot dead, while in February, a candidate for mayor in the city of Puerto López was killed.
Witnesses say Mr. Villavicencio was attacked as he was leaving a campaign event at about 18:20 (00:20 GMT) local time.
Mr. Villavicencio’s uncle, Galo Valencia, described the moment his nephew was killed: “We were just a few meters from the school when we were hit by a hail of about 40 bullets.”
A state of emergency has been declared and current President Guillermo Lasso has pledged that the “crime will not go unpunished”.