Answered by Borut | Jan. 10, 2024 00:20
You are actually looking for 144 hour visa free transit and not 72 because 72 hour was replaced by 144 hour years ago in Shanghai area.
Whether you are eligible or not is based on your itinerary. In short, if your immediate points (of any kind, regardless if they are done by ship or plane) before and after Shanghai are in two different countries or eligible territories (eligible territories: Hong Kong, Taiwan and Macau), then you are eligible to enjoy 144 hour visa free transit in wider Shanghai area and you will be able to exit the ship visa free and to enjoy the city on your own or by taking a tour.
If your stay in Shanghai is shorter than 24 hours, based on your scheduled arrival and departure, then you will be covered by 24 hour visa free transit. If your stay is just a minute longer than 24 hours, then 144 hour visa free transit applies. In any case, you do not need a visa and you will be allowed to explore the wider area of Shanghai. Again, under the assumption that your itinerary is eligible as explained above.