Sodium-glucose cotransporter 2 inhibitors (SGLT2i) have recently become a standard treatment for heart failure and renal failure. The number of patients using these drugs is expected to increase further. However, no adverse drug event profiles have been published for the use of SGLT2i in patients without diabetes. To analyze and clarify the differences in adverse event profiles associated with the use of SGLT2i in patients with diabetes or heart failure using the Japanese Adverse Drug Event Report (JADER) database, a Japanese reporting system for adverse events. The JADER database, containing reports submitted between April 2004 and January 2024, was used. Our study focused on patients with diabetes or heart failure, analyzing adverse events associated with empagliflozin and dapagliflozin. The reporting odds ratio (ROR) and 95% confidence interval (CI) were calculated for signal detection. We identified risks of adverse drug events such as ketoacidosis, urinary tract infection, dehydration, and acidosis in both patient groups. However, the risks of cerebral infarction and ischemic heart disease were identified only in patients with diabetes, while risks of renal dysfunction, hypoglycemia, and sepsis were identified only in those with heart failure. Adverse events should be managed appropriately for patients using SGLT2i, as the adverse event profiles differ between those with diabetes and those with heart failure. Understanding these differences is crucial for improving patient safety and optimizing treatment outcomes.