Berlin has a long history as the capital of Germany. It began as two small fishing villages on the River Spree in the 13th century and grew into one of Germany's richest cities by the 15th century. During the 18th century, many grand buildings were constructed, transforming the small settlements into an important port and trading center. Berlin became the official capital of a unified Germany in 1871. The city faced great destruction during World War 2 but was rebuilt after the war ended. Berlin was then divided by the Berlin Wall from 1961 to 1989 during the Cold War, separating East and West Berlin until the wall was torn down.