In the 11th century it fought successfully against the more powerful Milan, until the latter's troops besieged and destroyed it in 1111. In 1158 the town was rebuilt by emperor Frederick I Barbarossa a few kilometers afar, originating the modern Lodi.