This study was based on the 2015–2018 National Health and Nutrition Examination Survey database. The relationship between the concentration of 10 distinct metals and metalloids (cadmium, total mercury, lead, selenium, manganese, chromium, cobalt, inorganic mercury, ethyl mercury, and methyl mercury) and dyslipidemia (assessed by serum lipid markers) was examined through multivariate adjusted modeling and restricted cubic spline (RCS) modeling. The study demonstrated that selenium was the only element with a statistically significant association with dyslipidemia. The RCS analysis showed a notable elevation in the likelihood of dyslipidemia when selenium levels surpassed 164 μg/L. This study’s findings indicate a positive correlation between blood selenium levels and dyslipidemia, underscoring the necessity of incorporating environmental factors into cardiovascular disease prevention strategies.