Story highlights Some Spaniards rally, calling for an end to the monarchy

It is "time to hand over to a new generation," the King says in a televised statement

Crown Prince Felipe will succeed the King

Many feel King Juan Carlos' finest hour was a stand against a coup

After nearly 40 years on the throne, King Juan Carlos I of Spain said Monday that he will be stepping down.

It is "time to hand over to a new generation -- younger, with a lot of energy -- that can, with determination, take on and carry out the changes that the current situation demands, and to face with intensity and determination the challenges of tomorrow," he said in a televised statement, according to a CNN translation.

"The long, deep economic crisis we are going through has left a lot of scars socially, but it has also pointed toward a future of hope," he said.

Crown Prince Felipe , 46, will succeed his father. The King said he decided it was "time to prepare and pave the way so that he who is in better conditions can continue."

Prince Felipe is "stable" and has "the maturity, the preparation, and the sense of responsibility necessary" to serve as king and "to lead to a new stage of hope using his experience and the drive of a new generation," King Juan Carlos added.

JUST WATCHED Former Greek king on Spain's Juan Carlos Replay More Videos ... MUST WATCH Former Greek king on Spain's Juan Carlos 09:44

JUST WATCHED Spain's King Juan Carlos: I quit Replay More Videos ... MUST WATCH Spain's King Juan Carlos: I quit 02:11

Photos: Abdications through history Photos: Abdications through history Abdications through history – Spain's King Juan Carlos I, left, announced Monday, June 2, that he would be handing over the throne to Crown Prince Felipe, center. Juan Carlos, 76, oversaw Spain's transition from dictatorship to democracy after the death of Francisco Franco in 1975. Hide Caption 1 of 5 Photos: Abdications through history Abdications through history – Beatrix of the Netherlands, center, greets the public on the balcony of Amsterdam's Royal Palace after her abdication in April 2013. She spent 33 years as the Dutch Queen before handing over power to son Willem-Alexander, left. Hide Caption 2 of 5 Photos: Abdications through history Abdications through history – King Albert II of Belgium, right, abdicated the throne in July 2013. Taking his place was former Crown Prince Philippe, left. Hide Caption 3 of 5 Photos: Abdications through history Abdications through history – Pope Emeritus Benedict XVI, left, greets his successor, Pope Francis, in December 2013. Earlier in the year, Benedict became the first pope to resign in nearly six centuries. Hide Caption 4 of 5 Photos: Abdications through history Abdications through history – Britain's King Edward VIII gave up the monarchy because he wanted to marry an American divorcee. He abdicated in 1936. Hide Caption 5 of 5

Prime Minister Mariano Rajoy first announced the King's decision.

Spaniards generally hold King Juan Carlos, 76, in high regard for his service to the nation and his defense of democracy after the death of the dictator Francisco Franco in 1975.

But the King's popularity took a hit in 2012 over a controversial elephant-hunting trip to Africa while the nation was mired in a deep economic crisis.

The focus of his reign was to bring about reconciliation between Spaniards of different political persuasions and from different regions.

Many consider the King's finest hour to be his decisive stand to halt a right-wing military coup in 1981, when he went on television to say that the monarchy would not tolerate attempts to interrupt democracy by force.

Some push for end of monarchy

Thousands of people demonstrated in Madrid and elsewhere, calling for an end to the monarchy altogether after the announcement Monday.

They waved flags and chanted: "La monarquia es una porqueria!" In English, that phrase means "the monarchy is garbage."

On the global campaign website Avaaz.org, a petition calling for a referendum on the future of the monarchy quickly racked up more than 100,000 signatures. Most were from people indicating that they were in Spain.

"This is a historic opportunity to promote a broad public debate to help regenerate our democracy and determine the future of the monarchy," Luis Javier wrote in the petition.

The call was echoed on Twitter, with some users also posting photos of elephants, saying they were celebrating the King's abdication.

Oversaw democracy's return

Born in Rome in 1938, Juan Carlos didn't set foot in Spain until he was 10. In Franco's Spain, he carried out military training and became the first Spanish officer to hold the rank of lieutenant in all three branches of the military.

In 1969, he was invested as crown prince and the designated successor to Franco.

On November 22, 1975 -- two days after Franco's death -- Juan Carlos was crowned king of Spain, restoring the monarchy after a 44-year interregnum.

In 1977, he enacted political reforms that led to Spain's first democratic election since 1936.

During his reign, Spain grew into an economic powerhouse and a vacation playground for Europe.

The King and Queen Sofia had three children and numerous grandchildren, styling their monarchy as accessible and relatively austere.

Hunting trip dented image

The private trip to Botswana in 2012 became public only after King Juan Carlos fell, broke his hip and was rushed back to Madrid for surgery.

With millions of Spaniards unemployed, the expense of the African trip caused an outcry. That prompted the king to make a rare apology in which he said he had made a mistake that would not happen again.

The King had previously expressed his concern about the impact of the crisis on Spaniards and called on the nation to come together to get through the tough times.

Other recent scandals have also damaged the monarchy's image.

Princess Cristina, the king's youngest daughter, is caught up in a tax fraud and money laundering investigation. She and her husband, Inaki Urdangarin, have denied any wrongdoing over his business dealings and the alleged diversion of public funds.

The scandal has created unprecedented problems for the royal family and kept the country riveted.

There have been open calls for the King to abdicate in favor of Prince Felipe, who is seen as untouched by the scandals.