In any 'loop' of a circuit, the voltages must balance: the amount generated = the amount used
This "Voltage Loop" law was discovered by a fellow named Kirchhoff (thus it is called Kirchhoff's Voltage Law = KVL). And we can see the loop above, where one part is made of the +9V battery. The other half must use up the +9v (making it -9V so that both halves of the loop equal out).
So what does this have to do with the Forward Voltage of an LED? Well, the Forward Voltage is the 'negative voltage', used by the LED when it's on. Kinda like a 'negative battery'! So lets modify our diagram slightly.
Let's say we have the same circuit above, except this time its a 5V battery and an LED with a forward voltage of 2.5V, how much voltage must be 'absorbed' by the resistor?
Let's say we have the same circuit above, except this time its a 5V battery and an LED with a forward voltage of 3.4V, how much voltage must be 'absorbed' by the resistor?
Next we're going to throw in another important law. This one is called Ohm's Law- and it describes how resistors work.
Voltage across a resistor (volts) = Current through the resistor (amperes)* The Resistance of the resistor (ohms)
There's a more common shorthand notation which you'll see very often:
V = I * R
Or the two other ways of writing to solve for current or resistance:
I = V / R
R = V / I
The V is for voltage, the R is for resistance and the I, confusingly, is for current. Yeah, that I is a little annoying isn't it, since theres not even a single I in the word current? Unfortunately, there are 100 years working against us here, so just bear with us on that one.
If I have a 3 ohm resistor (R) with a current of 0.5 Amperes (I) going through it. What is the voltage (V) across the resistor?
Now I have a 1000 ohm resistor (R), and a voltage across it of 6.8V (V), what is the current (I) going through the resistor?
The amount of current (I) going through an LED is directly proportional to how bright it appears.
Aha! Finally, the last piece of the puzzle. If we increase the current, the LED will be brighter. Likewise, if you decrease the current, the LED will be dimmer. By picking the correct resistor, you have full control over how the LED appears.
Most of the time, you'll want to have a really bright LED so you'll be calculating the smallest resistor you can get away with and not damage the LED. But note that the more current used by the LED, the quicker you'll drain the battery. So there are good reasons for wanting to control the brightness if say you have a small battery and you want the lights to last a long time.
Since as we have seen, too much current will make the LED go poof, what is the best amount of current we should use? For some very big 'power LEDs', the current can be as high as 1 or 2 Amperes, but for pretty much every 3mm, 5mm or 10mm LED, the amount of current you're expected to use is 20mA. You can see this in the datasheet we talked about earlier. See the right-most column? IF is the Forward Current (I) and they use 20mA.