The electromagnetic force bears some resemblance to gravity in that it is infinite and obeys the inverse square law. However, this is where the similarities end. The electromagnetic force is 10^43 time stronger than gravity and, more importantly is has both a positive and negative charge. This positive and negative charge lead to important implications in the world around us and provide some serious benefits, including the wonder of electricity which is what is powering the internet, your computer and all the wi-fi equipment you are using to read this. But where does the electromagnetic force come from? For this we need to go deep into the heart of an atom…
Atoms are made up of protons, neutrons and electrons where, conceptually, the protons and the neutrons form the centre of the atom, the nucleus, and the electrons orbit this nucleus rather like the planets orbit the Sun in our solar system. Within the nucleus the protons have a positive charge, the neutrons are neutral, or no charge, and the electrons have a negative charge. The protons and electrons have exactly the opposite charges and make the overall atom neutral, or without charge. There are generally always the same number of electrons as there are protons in an atom.
An important point here is that like charges repel each other and opposite charges attract. You can demonstrate this by trying to push the north poles of two magnets together, it is very difficult or even impossible if the magnets are of a suitable size. However, a north and south pole will attract each other strongly and you will not be able to keep them apart when they get close together.
In heavier elements (atoms containing more protons, neutrons and electrons) some of the electrons are able to leave the atom and join another atom the is next to it when a difference in charge is applied. Rubbing an balloon against your jumper transfers electrons from one to the other leaving a difference and resultant charge on the balloon. It is the movement of these electrons from one atom to the next that generates the magnetic field which powers things such WI-FI, mobile phones, TV and radio broadcasts, satellite transmissions and the radio signals given of by pulsars in space. Conversely moving a magnet will generate an electric field. These two concepts are used in electric motors, electricity generates a magnetic field which attracts the magnetic rotor and turns the shaft, and in a generator where a magnet is spun in the middle of a coil of wire and generates an electric field which produces electricity in a coil of wire.
The electromagnetic force travels through space, even the vacuum of space, as waves and these waves have a property called wave length, the distance between two peaks. This property gives rise to the electromagnetic spectrum which encompasses all the things I have already mentioned (radio, TV satellite broadcasts) but also includes microwaves, infrared light, ultra violet light, X-rays and gamma rays. However, the light that you are reading this by, the light that illuminates your room or location and the light that comes from the Sun is and electromagnetic wave sitting in between a narrow window between infra red and ultraviolet light. Light is an electromagnetic wave, the electromagnetic force.
Important!
Information taken from Universe, 9th edition, Freedman et al, 2011, ISBN-10: 1-4292-3153-X