Depends on the dose
Epsom salts are Magnesium Sulfate which is safe for human consumption in limited doses.
You may notice on the epsom salt container that it can be used as a laxative
, which is the effect of ingesting larger amounts of magnesium sulfate. Ingestion of too much could lead to problems due to the laxative effect, but again a small amount should not be dangerous when used appropriately.