Imagine sitting on a swing at a playground with nobody around to give you a push. To get yourself into a larger and larger swing, you swing your legs back and forth. Of course, you can't just swing them randomly back and forth, you need to swing them back and forth one time for each back and forth oscillation of the swing. This is resonance.
When an object (like the swing) has a particular natural frequency at which it tends to oscillate, it can be made to go into larger oscillations by adding in small amounts of energy at just the right time during each oscillation. This can be done by an external force that acts with the same frequency as the natural frequency of the object oscillating.
In the simulation below, three identical 2 kg masses are attached to three springs with varying spring constants. Each mass spring combination has a certain natural frequency. When the bar to which the masses are attached is itself is oscillated, the three masses will all start to move slightly. If the frequency of oscillation of the bar matches the natural frequency of vibration of any one of the mass/spring systems, resonance will occur. The particular mass will get into a vibration mode with a larger amplitude. Note: All the springs have built-in damping that prevents the resonance from getting too large.