King Juan Carlos of Spain has announced his intention to abdicate, after nearly 40 years on the throne.
“A new generation must be at the forefront… younger people with new energies,” the 76-year-old king said in a televised address.
His son, Crown Prince Felipe, 45, will take over the throne.
For much of his reign, Juan Carlos was seen as one of the world’s most popular monarchs, but recently many Spaniards have lost confidence in him.
His reputation has been tarnished by a long-running corruption investigation into the business dealings of his daughter and her husband.
King Juan Carlos, 76, has had health problems in recent years
Support for the king fell further when it was discovered he had been on a lavish elephant hunting trip to Botswana in April 2012, in the middle of Spain‘s financial crisis.
The first announcement about the abdication came from Prime Minister Mariano Rajoy, who told reporters: “His Majesty King Juan Carlos has just informed me of his desire to renounce the throne and begin the process of succession.”
Later, the king himself said in a televised address that it was time for a “new era” in which a new generation could take on the transformations and reforms required.
He said his son, Prince Felipe, had the maturity and preparation to be king.
The prime minister said Juan Carlos had been a “tireless defender of our interests”.
“I‘m convinced this is the best moment for change,” he added.
Juan Carlos took the throne on the death of General Francisco Franco, the right-wing dictator who ruled for 36 years after his victory over Republican forces in the Spanish Civil War.
The king became Spain‘s first crowned head of state for 44 years.
But he soon ignored Franco’s supporters, who wanted an extension to autocratic rule, and ushered in a new system of parliamentary monarchy.
As the years went on the king involved himself less in day-to-day politics, and became more of a figurehead.
He has been credited as a stabilizing force for independence-minded areas such as Catalonia and the Basque region, and he also helped defuse an attempted coup in 1981.
Until a few years ago his popularity was high, but the hunting trip and corruption allegations involving his youngest daughter, Cristina, and her husband Inaki Urdangarin, led to calls for him to step aside.
The king’s son and successor, Felipe, appears to have been untarnished by the scandal.
Felipe and his wife – former television presenter Princess Letizia – have recently taken on more important roles in ceremonial events.
On social networks, people are already asking whether it is time for Spain to become a republic, and some parties are calling for constitutional reform and a popular vote to pave the way for this change.
But the two main parties in parliament remain loyal to the monarchy, our correspondent says.