Real Madrid great Casillas confirmed his intention to stand for the position in February, but his withdrawal means Luis Rubiales is expected to be re-elected unopposed in August.
Casillas, who won Euro 2008 and 2012 alongside the 2010 World Cup with Spain, explained via a Twitter post his decision was in part due to "the exceptional social, economic and health situation that our country is suffering".
"This makes the elections take a back seat," he added. "I think it is time to add and not divide."
The former Madrid goalkeeper, who made 167 senior appearances for his country, insists the decision to pull out does not mean a "closed door for the future" and said he could opt to run for the position further down the line.
"I wanted a fair, transparent and truly participatory electoral process, looking for the best for Spanish football," he said.
"I hope that in the next elections it can happen with me or with other candidates."
Spain has been one of the worst-affected countries of the pandemic, with over 290,000 confirmed cases of COVID-19. Of those returning a positive test, 27,136 people have died.
Casillas won five LaLiga titles and three Champions Leagues with Madrid before departing his boyhood club for Porto in 2015.
The 39-year-old suffered a heart attack in May 2019 and was later added to the club's backroom team, with Porto president Jorge Nuno Pinto da Costa announcing Casillas had retired from playing in February.