Is a Visa required for a 15 hour layover in Narita Airport, flying in from South Africa? Ticket included departure from SA, with a 3hour stopover in Doha, 15 hour stopover in Narita Airport, with final destination to Dalian. However Customs prevented boarding. Ticket had to be changed to following day, with astronomical additional costs, hotel changes, new PCR tests etc. The trauma experienced was inexplicable.
Sounds like you've answered your own question, it's required, so they wouldn't let you board.
If you're not from one of the list of countries here, you will need a transit visa.
Based on your post I'm assuming South Africa, so yes, you'd need one.
It's possible if transiting the same calendar day, as per the above link as well.