A LED is a light emitting diode, in other words a light source made of semiconductor materials.
Since a LED is a diode, it works like a diode. At the same time, while diodes are basically silicon based semiconductors, the p- and n-layers of a LED are manufactured from a compound with two or more constituent parts. The reason for this is that only recombination in the so-called direct semiconductors[1] is accompanied by light emission.
The key part of a LED is a tiny diode. In order to restrict dispersion of the emitted light to the extent possible, the diode is placed in a parabolic mirror. The n-layer of the tiny diode chip is in contact with the parabolic mirror. This electrode is called the cathode (-). The upper part of the diode chip is the p-type layer. The p-type layer is connected to the leg called anode (+) by a thin wire.
If the cathode and the anode of the LED is connected to the negative and positive potentials of the direct current source, respectively, the LED will light up if there is enough voltage. The photon is emitted by the p-n junction of the light emitting diode. About one per cent of the recombination of electrons and holes is accompanied by photon emissions. The LED emits incoherent light in a narrow spectrum. During production, one leg of the LED is made longer – this is the anode – and the other leg shorter, this will be the cathode.
Provided the size difference was not enough during the use of the diode to distinguish the two electrodes, it can be seen from top view that the edge of the LED is cut off at the cathode side.

The LED opening voltage (the lowest voltage level the energy of which overcomes the energy of the internal electric field of the blocking layer and at which the LED starts illuminate) is a value other than zero and depends on colour of the light emitted by the LED.

As discussed with diodes, a LED conducts electricity in only one direction. If connected to an alternating current power source, it would light up in one of the half periods and not in the other, which can be demonstrated by spinning around a LED attached to a long twin wire as seen on the picture below.