Scans revealed swelling in his right thigh, leading to medical advice against competing, which Alcaraz announced on social media.
Alcaraz expressed his heartbreak at not being able to represent Spain, stating it was the “greatest thing there is”.
Spain will now face Czechia in the Davis Cup quarter-finals without the six-time Grand Slam champion.
Alcaraz has previously advocated for changes to the Davis Cup format, suggesting it should be held every two or three years to increase player commitment and appeal.