Expect an electrical force exerted on something charged when it’s close to a charged object. Re-imagine the thing extracted from it’s environment by choosing to replace the charged object by an electrical force exerted on the thing.
The re-imagining is simpler, and useful if the tension force is chosen so that it has the same effect as the stretched surroundings that it replaced.
Expect a magnetic force exerted on a magnetic object when it’s close to a magnet. Re-imagine the thing extracted from it’s environment by choosing to replace the magnet by a magnetic force exerted on the thing.
The re-imagining is simpler, and useful if the magnetic force is chosen so that it has the same effect as the magnet that it replaced.