The settlement was originally called Rajhenburg in Slovene, after Reichenburg Castle in the settlement. This name was attested in written sources in 895 as Richenburch. The name of the settlement was changed from Rajhenburg to Brestanica in 1952. The name was changed on the basis of the 1948 Law on Names of Settlements and Designations of Squares, Streets, and Buildings as part of efforts by Slovenia's postwar communist government to remove German elements from toponyms. The name Brestanica was originally a hydronym referring to Brestanica Creek, which runs through the settlement and is a tributary of the Sava River. The creek name was attested in written sources circa 1500 as Brestanza, and in the 16th century as Prestonicz. The hydronym is derived from *Brěstovьnica, literally meaning 'elm creek'.
History
A prehistoric settlement probably stood on the hill above Brestanica, where the castle is now located. Remnants of the Roman era include milestones from the Roman road along the Sava and traces of a bridge across the river. A settlement was attested below Rajhenburg castle as early as the 13th century, and it received market rights in the 14th century, including the right to four annual fairs. The settlement was plundered and burned in an Ottoman attack in 1476. Unsuccessful peasant attacks on the castle occurred in 1515, 1573, and 1583. In 1595, the archbishop of Salzburg granted the settlement and castle to the Moscon family, who were followed by the Gradneck, Gallenstein, and Attems families. A school was established in Brestanica in 1774. On 5 November 1918, armed miners and farmers marched on Brestanica, demanding that merchants sell them goods at low cost. The Communist Party had a strong presence in Brestanica from 1938 onward.
Mass grave
Brestanica is the site of a mass grave associated with the Second World War. The Hafnar Ravine Mass Grave is located in the Hafnar Ravine along Suhadol Creek, opposite Rajhenburg Castle. It contains the remains of up to 186 Croatian and Serbian soldiers, as well as 20 to 30 Slovene civilians.
Castle
On a hill on the right bank of the Sava River, south of the settlement, is Rajhenburg Castle. It was first mentioned in written documents dating to AD 895, making it the earliest documented castle in Slovenia. It has preserved some of its Romanesque features and an early Gothicchapel, but most of its current structure dates to around 1600. During the Second World War it was used as a deportee collection centre by the German forces. From June 1948 to October 1956 the communist authorities used the castle as a penal institution for female political prisoners.