A stockade is an enclosure of palisades, tall walls made of logs placed side by side vertically, with the tops sharpened to provide some security.
Stockade fortifications were simple forms of defense of military camps or settlements, used since Roman times and prior to that. The troops or settlers could build one by clearing a space of woodland, and using the trees whole or chopped in half, with one end sharpened. A narrow trench was dug around the area, and the sharpened logs placed standing side-by-side inside it, encircling the perimeter. Sometimes additional defense would be added with the placement of punji sticks in a shallow secondary trench outside the stockade. In colder regions, sometimes the stockade received a coating of clay or mud, that would make the crude wall wind-proof.
Stones or thick mud layers could also be placed at the foot of the stockade, improving the resistance of the wall. From that, the defenders could, if they had the materials, raise a stone or brick wall inside the stockade, creating a more permanent defense while working protected.
Stockade walls are used as garden fencing in modern days, made of finished planks, more intent on privacy and decoration than on security.
The word stockade also refers to a jail in an army camp, or a crude prisioner camp, or even slave camps. In this case, the stockade is used to keep people inside, rather than out.