The IO pin will be 5V tolerant if the supply voltage Vdd is present, and they are configured as inputs. VDDIO must be applied to the microcontroller when input voltage is 5V, or else the 5V tolerance does not apply.