a well or pit dug into the ground: most often a shaft sunk by hand to reach underground water
A well of this kind is neither a natural spring nor a rain-fed storage tank. It is a hole dug straight down until the diggers strike the water flowing beneath the ground, so a good one gives fresh, running water year after year. Digging one was hard, valuable labor, which is why owning a well mattered so much, and why so many of these verses turn on who dug it and who has the right to draw from it.
The same word names a plain hole in the ground when no water is in view. The tar pits where the kings fell (Genesis 14:10) are called by this word, and so is the deep hole that pictures death and ruin in the Psalms and Proverbs: a pit with a mouth that swallows a person and will not let go.
Both uses are the same picture, a shaft cut down into the earth. Whether it saves life by giving water or ends life by trapping whoever falls in depends entirely on what the hole holds and how the writer is using it.