Nuria Parrizas Diaz will take Osaka's spot as the lucky loser and will take on Sara Sorribes Tormo in her first-round game.
Osaka sustained the ankle injury during her opening round win at the Mutua Madrid Open last week. The Japanese player beat Anastasia Potapova in straight sets, but struggled in the second match as she lost 6-3 6-1 against Tormo.
In a statement, the former world number one said: "Unfortunately I'm going to have to withdraw from Rome as the injury which I picked up last week in Madrid hasn't healed yet.
"It's an Achilles injury so I need to be careful especially in advance of Roland Garros.
She added: "I love this city and always enjoy playing in front of the Italian fans so I will be sorry to miss them - but look forward to coming back next year."
The four-time Grand Slam winner recently made the Miami Open final but lost 6-4 6-0 against newly crowned world number one, Iga Swiatek. The 24-year-old will now set her sights on the upcoming French Open.
Osaka wasn't the only injury casualty in Rome as Denmark's Clara Tauson also withdrew.
The player cited a lower back injury and will be replaced by Madison Brengle for the opening round clash against Ukraine's Marta Kostyuk.