Tanah Lot means "Land in the Middle of the sea" in Balinese language. Located about 20 km from Denpasar, the temple sits on a huge offshore rock which has been shaped continuously over the years by the ocean tide.

Tanah Lot is said to be the work of the 15th century priest Nirartha. The story goes that during his travels along the south coast he saw the rock-island's beautiful setting and rested there. Some fishermen saw him, and bought him gifts. Nirartha then spent the night on the little island. Later he spoke to the fishermen and told them to build a shrine on the rock for he felt it to be a holy place to worship the Balinese sea gods.