There do not appear to be clinical studies supporting the common belief that supplementing with electrolyte drinks or supplements improves symptoms of a hangover from drinking alcohol. In fact, a small study based on beer consumption by young men showed that it did not cause a loss of electrolytes: There was no effect on the excretion of sodium and there was actually a reduction in the excretion of potassium (Hobson, Alch and Alchism 2010). A study of the effects on alcohol consumption by older men showed only a short and small increase in urine production from stronger alcoholic beverages, but no impact on electrolytes (Polhuis, Nutrients 2017). On the other hand, there are many reports of people with chronic alcohol abuse (often with alcoholic liver disease) who develop electrolyte imbalances that require and can be treated, at least temporarily, with electrolyte supplementation (Baj, J Clin Med 2020; Palmer, NEJM 2017).
It appears that information about chronic alcohol abuse has been misconstrued to suggest that, after a night of drinking, you need to replenish electrolytes (such as sodium, potassium, magnesium, and calcium).
It is certainly wise to stay adequately hydrated (with water), before, during, and after drinking alcohol, and, preferably, to drink slowly, in moderation, and with food. It is also true that alcohol can somewhat increase urine output, providing more reason to consume water. But there does not seem to be evidence that a single bout of drinking causes electrolyte deficiencies or imbalances.
Electrolyte replenishment (often with some sugar) can be important after bouts of diarrhea (resulting primarily, in loss of sodium, chloride and potassium that would normally be absorbed in the large intestine), or after extended periods of strenuous activity -- typically 90 minutes or more (resulting, primarily, in the loss of sodium and chloride in sweat). ConsumerLab.com has tested, reviewed, and compared electrolyte supplements and sports drinks and identified Top Picks for these purposes.