Prime Minister Jose Luis Rodriguez Zapatero of Spain will not seek a third term in office after parliamentary elections due next year.
Mr Zapatero, whose popularity is at an all-time low, said it was the right decision for the country, his centre-left Socialist party and his family.
He became Prime Minister in 2004 after the Madrid train bombings.
Spain's economy was booming then. It has since suffered a deep recession, and unemployment is at 20%.
Mr Zapatero said he would stand down as party leader when a successor had been chosen.
A series of 'primary' elections will begin after local elections on 22 May.
The BBC reports the Socialists are currently 15% behind the Popular Party in the polls and are expected to suffer heavy losses.
Mr Zapatero said he was making his position clear now, a year ahead of parliamentary elections, in order to end the uncertainty and speculation over his future.
That was distracting the government from its main tasks, he said: lifting Spain out of recession and creating jobs.