No one was injured in the blast outside the building housing the Popular Party office, they said. Police cordoned off the area but there was no immediate word on who was responsible.
Spain is due to hold municipal elections across the country on May 27 and campaigning started in earnest yesterday.
Socialist Prime Minister Jose Luis Rodriguez Zapatero held a rally in Valencia, on Spain's east coast, today morning.
Spanish news agency Europa Press said the device that exploded consisted of a vacuum flask attached to a bottle with inflammable liquid and cited sources saying some sort of anti-globalisation group could be behind the attack.
The regional government in Valencia confirmed there had been an explosion that had damaged the building, but declined to comment further.
Attacks on political party offices are relatively frequent in the Basque Country region in northern Spain. Youth groups linked to armed group ETA carry out sporadic attacks using petrol bombs or homemade explosives.
ETA has killed 800 people in 40 years of bombings and shootings to back its demands for an independent Basque state. The government scrapped peace talks with ETA in December last year when the group bombed Madrid airport, killing two people in its first fatal attack since May 2003.
REUTERS SKB PM1852