Depends on the location, the alert comes usually as soon as the initial tremors are registered. If you're at the epicenter, tough luck. For example, for me in Tokyo, the alert came 2 minutes before it hit, and even then, the actual earthquake was extremely subtle.