The court gave a fifth man 10-year prison sentence in the same trial.
All of the men were accused of blowing up a car in November 2013 near a financial centre in the capital Manama "to disrupt a Formula 1 race," the agency said.
They were also accused of making and possessing explosives, detonating explosives and stealing a car.
Bahrain has held an annual three-day Grand Prix event since 2011.
Since mid-February 2011, thousands of pro-democracy protesters have held numerous demonstrations in the streets of Bahrain, calling for the Al Khalifa royal family to relinquish power.
On March 14, 2011, troops from Saudi Arabia and the United Arab Emirates invaded the country to assist the Bahraini government in its crackdown on peaceful protesters.
Scores of Bahrainis have been killed and hundreds injured and jailed by the regime forces since the uprising broke out.
In February, Amnesty International denounced the “relentless repression” of anti-regime protesters in the Persian Gulf kingdom, blaming Bahraini security forces for their repeated use of “excessive force to quash anti-government protests.”
RA/NJF