Moats were a vital defense for the Medieval castles and were probably the best form of defense a castle could have.
Enemy soldiers would have great difficulty overcoming a castle moat especially large and deep moats that slowed down the enemy and created a fantastic barrier between the castles defenders and attackers.
Most moats were then filled with water to make them impassable for an enemy.
A medieval castle moat was typically constructed by first digging a ditch all around the castle walls.
If the castle was located near a water body, the moat was then filled up with water.
If water was not readily available, the castle defenders would often choose to set up wooden stakes and other obstacles in the wide ditch to make it impassable for the attackers.
In some cases, a drawbridge was used for the same purpose which had the added advantage that it could be lifted in times of danger, effectively eliminating any passageway from or to the castle.
A bridge was often erected to enable the castle inhabitants to cross the moat.
Such a bridge was then heavily guarded since it was the only entrance to the castle.