The top-seeded Spaniard was leading 7-6(3), 2-1 when Shapovalov was forced to stop after suffering an injury while stretching for a running forehand. The match lasted 82 minutes.
Alcaraz survives a tight opening set
Shapovalov made life difficult for the defending champion throughout the opening set and created a set point at 5-4.
Alcaraz, however, responded with a delicate drop shot to escape the danger before forcing the set into a tie-break.
The Spaniard then took control of the tie-break to win 7-3 and move within a set of the semi-finals.
Shapovalov unable to continue
The Canadian appeared to experience discomfort early in the second set after stretching for a running forehand.
He received an off-court medical timeout following the opening game but returned visibly restricted.
Shapovalov managed to play on for a short period, but with Alcaraz leading 2-1, he eventually decided he could not continue.
The retirement sends Alcaraz into the final four as he continues his bid to successfully defend the Japan Open title.
Alcaraz faces Munar in all-Spanish semi-final
Alcaraz will face fellow Spaniard Jaume Munar in the semi-finals.
Munar reached the last four after defeating French qualifier Kyrian Jacquet 6-4, 6-2 earlier on Sunday.
The all-Spanish encounter guarantees that one Spanish player will reach the Japan Open final for a second consecutive year.
Alcaraz has won their previous four meetings? Wait: current reporting says Alcaraz leads their head-to-head 3-1, so the semi-final will be their fifth meeting.
Alcaraz continues title defence
The victory keeps Alcaraz's title defence alive in Tokyo after he returned to competition following a four-month wrist injury layoff.
He had earlier defeated Matteo Arnaldi 7-6(6), 6-1 in the second round after recovering from a 6-2 deficit in the opening-set tie-break.
The Japan Open is an ATP 500 tournament being played on hard courts in Tokyo from 30 September to 6 October.
With a place in the final now within reach, Alcaraz will look to overcome Munar and take another step towards retaining his Tokyo crown.
