All bodies of a sufficiently large size have gravity. This gravity usually (but not always) exerts a force equal to the standard gravitational attraction on the surface of an Earth-sized planetary body. Gravity in the Spelljammer universe is also an exceptionally convenient force, and almost always works such that "down" orients itself in a manner most humanoids would find sensible.
In planet-sized objects, gravity is directed toward a point at the center of the planet so that people can stand anyway on the surface and dropped object fall perpendicular to the surface. In smaller objects, like space crafts, gravity is not a central point but rather a plane which cuts horizontally through the object. The gravity plane is two-directional; it attracts from both top and bottom. A sailor can actually stand on the bottom of the ship's hull and move around as easily as if he was walking on the deck.