If it is transponder key
it could be the code reader in the ignition switch is wrong. However, if it is a normal key, then I do not see any reason why the switch goes wrong could lead to the symptom you mentioned. It appears to me something need time to build up to reach the start level. The most related item would be fuel pressue is low and insufficient fuel reached the fuel injector.