Coastal and inland regions face different disaster risks. Whether one is "safer" depends on specific disaster types.
Coastal areas face tsunamis, storm surge, hurricanes/typhoons, and saltwater corrosion. Rising sea levels increase these risks. However, coastal areas tend to have frequent earthquake risk assessments and developed response infrastructure.
Inland areas typically have low tsunami and storm surge risk. However, many inland areas suffer from river flooding, landslides, and inland hurricane impact. Mountainous and basin terrain particularly face dangerous landslides.
Earthquake risk exists inland too. Areas far from the Ring of Fire have low risk, but regions like central U.S. have old fault lines with occasional earthquakes.
Safest locations are inland plains far from high earthquake zones, not in floodplains, and far from high mountains.