Founded in 1795 by the Chinese Kapitan Chua Su Cheong during the Dutch colonial era, the temple was originally built as a place for the community to offer prayers for their ancestors buried on Bukit Cina, the world's largest traditional Chinese cemetery outside of China.
The temple is primarily dedicated to Tua Pek Kong (the God of Prosperity/Earth Deity). Its alternative name, Sam Po Kong, stems from local legends associated with Admiral Zheng He (San Bao Eunuch). One popular lore tells of a sam poh fish that saved the Admiral's ship from sinking by plugging a hole in the hull. While historically a Taoist ancestral temple, it has become an iconic pilgrimage site for those honoring the legacy of the Ming Dynasty’s maritime expeditions to Melaka.