It was first mentioned in writing before 1250 AD, and it served as the capital of the Dithmarschen, a peasant republic with Allies in the Hanseatic league dating from 1468. The city was sacked in 1500 AD when King John of the Kalmar Union attempted to conquer the republic. His forces were routed by a force with poor arms and inferior numbers in the Battle of Hemmingstedt. In 1559, the republic was conquered, and the city lost its municipal rights, and would not regain them until 1869.
Over time it lost the capitalship to the town of Heide, which developed a larger economy.