This is a study in adults who had a heart attack (myocardial infarction). The purpose of this study is to find out whether a medicine called empagliflozin helps to lower the chances of having to go to the hospital for heart failure and whether it lowers the chances of dying from cardiovascular disease. People who are in hospital may join the study soon after being treated for their heart attack. Participants are put into 2 groups by chance. One group takes 1 empagliflozin tablet a day. The other group takes 1 placebo tablet a day. Placebo tablets look like empagliflozin tablets but do not contain any medicine. All participants continue their standard treatment. Empagliflozin belongs to a class of medicines known as SGLT-2 inhibitors. Empagliflozin is a medicine that helps people with type 2 diabetes to lower their blood sugar. Researchers think that empagliflozin might also help people after heart attack who are at risk for heart failure, whether or not they have diabetes. Participants are in the study for about 1 to 2 years. During this time, there are about 4 visits in person, 2 visits are done either by phone or by use of an mobile application. Results between the empagliflozin and placebo groups are compared. The doctors also regularly check the general health of the participants.