Trang Province, on Thailand's western coast, lacks a pre-Rattanakosin historical record but emerged as a significant area during the early Rattanakosin era (1782–1851). The city’s early references, notably in a 1773 inscription from Nakhon Si Thammarat, identify Trang as one of twelve surrounding towns under the "twelve zodiac town" governance system, represented by the zodiac horse. Although not a major settlement originally, Trang gained importance as a coastal transit point for journeys to other southern cities, such as Nakhon Si Thammarat and Phatthalung, by the Ayutthaya and Thonburi periods.
Trang’s formal status evolved under King Rama I in 1804, temporarily placing it under Bangkok's direct control due to local political tensions, before its return to Nakhon Si Thammarat oversight. King Rama II formally established Trang’s governance, appointing Phra Uphaithani as the first governor, and setting up a city pillar in Khuan Thani in 1838. Trang continued to experience governance shifts, moving under direct Bangkok administration to prevent conflict and ensure stability.
Significant development took place under King Chulalongkorn (Rama V) in 1890, who appointed Phraya Ratsadanupradit Mahitsaraphakdi (Khaw Sim Bee Na Ranong) as Trang's governor, relocating the city center to Kantang near the Trang River and combining Trang with Palian as a major trade center. This period also saw the province pioneer rubber tree cultivation, establishing a key industry. In 1916, King Vajiravudh (Rama VI) relocated the provincial capital from flood-prone Kantang to Thap Thiang in the safer, central Bang Rak District, now Trang City. Trang became an official province in 1933, solidifying its administrative status within Thailand.