 <p>If you examine the code you see that when the UIAlertView is being created it is being allocated too. So the retain count of the alert is 1 after that. If you read the apple documentation you will see that the [alert show] also increase the retain count of the UIAlertView. So, after that line the retain count will be 2. The line [alert release] will decrease the retain count to 1 again, because, for this code, isn't important to keep reference to the UIAlertView. So, after that, the retain count is 1, and the UIAlertView is being showed. When the user press the button to close the alert, the method that closes the alert will decrease the retain count to 0 and the memory will be freed</p>