We present a direct connection between torus knots and Hopfions by finding stable and static solutions of the extended Faddeev–Skyrme model with a ferromagnetic potential term. (P,Q)-torus knots consisting of |Q| sine-Gordon kink strings twisted P/Q times into the poloidal cycle along the toroidal cycle on a toroidal domain wall carry the Hopf charge PQ, which demonstrates that Hopfions can be further classified according to torus knot type.