Kajaani Castle was built in the beginning of the 17th century and was destroyed in the Great Northern War in 1716. The unrest in Russia in the 17th century, accelerated the progress of building Kajaani Castle. The Castle was needed to stabilise the Lake Oulujärvi region and at the same time, to supervise the vital waterway between Ostrobothnia and Russian Karelia (i.e. the River Kajaanijoki), which was normally used by Russian traders.
In the 1660’s the castle controlled Swedish frontiers in the east as well as protected the Gulf of Bothnia coast. The castle was used also as a prison.
The Russian beat the Finnish army in the battle during the Great Northern War in 1714, a period also known as the Great Wrath. The Russians destroyed parts of Kainuu Region in order to invade Kajaani, too. The people in the castle were imprisoned and taken to Siberia. The castle was vacated and blown up. Only the stone ruin of the castle remained.