Although the area between Idrija and Žiri had already become a borderland after the end of the World War I, it was not until the signing of the Treaty of Rapallo in 1920 that the two settlements officially became parts of two different countries – Idrija became part of the Kingdom of Italy, while Žiri became part of the Kingdom of SCS (later Yugoslavia). When the World War II reached the area of Slovenia in April of 1941, the border started affecting people’s lives even more. This was due to the fact that the Italian side, which was expecting Yugoslavia to attack, mined some of the borderlands and relocated the local population to Italy’s interior.
After Yugoslavia’s capitulation, the adoption of Hitler’s guidelines for the division of Yugoslavia, and the signing of a treaty between Italy and Germany in July of 1941, the area became the place of contact between the Kingdom of Italy, the Italian-occupied Province of Ljubljana, and the German-occupied territory. All the way up to the sectoral boundary marker number 40, which was located near Spodnji Vrsnik, the new border was modelled after the Rapallo Border. At the aforementioned sectoral boundary marker, however, the border branched off to the East and continued north of Šentjošt nad Horjulom, past Polhov Gradec, and all the way to Šentvid pri Ljubljani.
The border remained passable and unmarked for some time, until the Germans started fortifying it in the spring of 1942. The entire border infrastructure was placed towards the Italian side, to patrol the border unobstructed. They drove stakes along the entire border and used them to tighten 2-metre- high meshes over it. In the areas where they were unable to set up the 2-metre-high meshes, they would only attach barbed wire on to the three rows of stakes. Next to the barrier, they placed 3 rows of 2-to-3-metre-wide barbed-wire on the ground. They also laid down landmines and grenades, which they would connect to the wire. Along with the physical obstacles being set up, the local population was also affected by the German clearing of the borderlands on the German side. The Germans cut out between 50 and 100 metres of the forest as well as demolishing multiple apartment buildings and outbuildings.