Huế (Vietnamese: [hwě] (listen) is a city in central Vietnam that was the capital of Đàng Trong Kingdom from 1738 to 1775 and of the Nguyen Dynasty from 1802 to 1945. A major attraction is its vast, 19th-century citadel, surrounded by a moat and thick stone walls. It encompasses the Imperial City, with palaces and shrines; the Forbidden Purple City, once the emperor's home; and a replica of the Royal Theater.