Trace elements like copper and zinc are supplemented in swine feeds to suppress bacteria and/or promote growth. Due to low absorption rates, trace elements are highly concentrated in swine feces, posing a risk to soil and human health if applied to agricultural fields. In the present study, the concentrations of six trace elements (Cu, Zn, As, Cd, Pb, and Cr) in pig feed and feces were evaluated by sample analysis and data from the literature. The feed‐to‐feces and feces‐to‐compost enrichment factors of the trace elements were determined to back‐calculate safe concentrations in feed needed to meet permissible trace element concentrations in organic fertilizers. The Cu and Zn concentrations in feeds were the highest, being statistically significantly higher in starter pig feeds than in grower–finisher feeds. Copper exceeded feed limits mainly in the feeds of finisher pigs and sows, while exceedance for Zn occurred in almost all feed samples. Concentrations above the limits were also observed for Pb and Cr impurities in mineral feed supplements. The highest Cu and Zn concentrations in feces were observed for starter pigs. Moreover, significant enrichment of trace elements from feeds to feces was found, with enrichment factors calculated as: 4.68–6.11 for Cu, 3.43–4.60 for Zn, 2.30–3.12 for As, 2.89–4.63 for Cd, 2.45–5.00 for Pb, and 3.32–5.00 for Cr. On this basis, the recommended calculated limits for Cu, Zn, As, Cd, Pb, and Cr in feeds for different ages of pigs were 41–53, 130–175, 2–3, 0.3–0.5, 5–10, and 15–23 mg/kg, respectively. Priority index calculations and the calculated recommended limits indicated that Cu in starter pig feeds and Cd in starter and breeding pig feeds should be prioritized for reduction to enable feces compost to be utilized safely in agricultural land amendment. Integr Environ Assess Manag 2022;18:978–987. © 2021 SETAC