Potential energy is energy that a system has because of how its parts are arranged, or energy that an object has because of where it is located. There are numerous types of potential energy, corresponding to various types of forces:
A system has gravitational potential energy if parts of the system have mass and are separated by a distance. The force of gravity enables parts of the system to do work on each other—that is, to exert forces that move each other for a distance.
An individual object with mass has gravitational potential energy relative to any other object with mass, provided the two objects are separated by a distance.
A system has electromagnetic potential energy if parts of the system have charge or are magnetized (and therefore exert forces that could do work on each other).
Individual objects have electromagnetic potential energy if they have charge and are located in an electric field, or if they are magnetized and are located in a magnetic field.