In the other words, load current, which is less than the specified 25 mA, doesn't damage the microcontroller pin driver.
Note, that a datasheet usually limits the total current of all pin due to overheating.
Example of calculation of the needed resistor:
R = (Vcc - Vol - Vled) / I
With the supply voltage Vcc=3.3 V, output low pin voltage Vol=0.3 V, LED saturation voltage Vled=1.5 V, and the desired LED current 5 mA:
R = (3.3 V - 0.3 V - 1.5 V) / 5 mA = 0.3 kOhm