The renormalization-group method is applied to investigate the infrared singularities in gauge theories with Abelian or non-Abelian symmetry, involving both massive and massless fermions. In the Abelian gauge model the infrared structures of massive and massless fermion propagators and of a massive fermion form factor are found. In the non-Abelian gauge model (quantum chromodynamics) the infrared behaviour of a massless gluon propagator and a massive quark form factor is considered in the logarithmic approximation.