For any object, the gravitational potential energy is a function of its height relative to some reference point. The common reference point is the ground, but this is arbitrary. A more scientifically correct choice would be a point in space at the center of Earth’s gravity field (which is not on the ground).
For example, if you lift a ball into the air before dropping it, it will have potential energy. When you drop the ball it will lose this energy and become a moving object with kinetic energy. The total amount of energy lost is equal to the initial potential energy plus the kinetic energy. This is because of the law of conservation of energy.
To determine an object’s gravitational potential energy, we use a simple equation: PE = mgh. Here m represents the mass of the object, h is its height above some minimum height level (which we arbitrarily choose as the ground), and g is the strength of gravity (9.8 N/kg on Earth).
The value of an object’s gravitational potential energy is directly proportional to its height above the zero position (which we arbitrarily choose as the floor). So doubling the height will result in a doubling of its potential energy and tripling it will result in a tripling of its potential energy. In unbound systems such as atoms, the potential energy is even more strongly dependent on the configuration of its particles and not their distance from each other.