The Harzburg, also called Große Harzburg ("Great Harz Castle"), is a former imperial castle, situated on the northwestern edge of the Harz mountain range overlooking the spa resort of Bad Harzburg in Goslar District in the state of Lower Saxony, Germany. It was erected from 1065 to 1068 at the behest of King Henry IV of Germany, slighted during the Saxon Rebellion in 1073-75, and a century later rebuilt under Emperor Frederick Barbarossa and his Welf successor Otto IV, who died here in 1218.