Noi Bai International Airport, Hanoi: The sensible option is a pre-booked shared limousine minibus direct to your Tam Coc/Trang An hotel: roughly 2.5–4 hours and US$15–20 per person. A private taxi is faster but poor value at about US$70. Do not go via central Hanoi unless you want to spend four-plus hours changing between airport transport and a train/bus.
Ninh Binh railway station: Use the north–south Reunification Railway from Hanoi, Hue or Dong Hoi, then take a taxi/Grab onward. The station is in Ninh Binh proper; Tam Coc is about 9 km southwest and Trang An lies west of town, so neither is a walkable station transfer. Confirm the drop-off address before boarding any through bus: ‘Ninh Binh’ and ‘Tam Coc’ are not interchangeable.