Protesters have hurled trash on a vehicle used by former Ecuadorean President Rafael Correa as he campaigns against a referendum that could prevent him from seeking re-election.

Correa's silver SUV was left covered in plastic plates, cups and mud in Wednesday's incident in the city of Quininde. The ex-head of state was trapped for almost three hours inside the building of a radio station where he was giving an interview as police controlled the protesters.

On Twitter Correa decried the incident as, "A shame for the country!"

Correa has been campaigning throughout Ecuador against a referendum being pushed by President Lenin Moreno, his one-time ally and now enemy.

The referendum includes one question that would make it impossible for Correa, who was president for a decade, to run again.