Kozy was historically located on lands held by the Silesian Piast branch of the Polish royal Piast dynasty. The village was in the Duchy of Oświęcim, located in the historic region of Upper Silesia. From 1327 the duchy was part of the Bohemian Crown lands (Kingdom of Bohemia). In 1457 the duchy was sold to the Polish king Casimir IV Jagiellon and returned to the Kingdom of Poland. In the accompanying document issued on 21 February the village was mentioned as "Dwe Kozy". Kozy was a privately owned village, owned by such wealthy noble families as Mikołaj Szłop of Dębowiec during the 15th century and from the early 16th century became part of the House of Saszowski estates.