What is the difference between an alert and a warning message?

Is there any difference between an alert and a warning message? When it should be used, under what condition and scenario?