The results of calculation of the three-loop radiative correction to the renormalization constant of fermion masses for non-abelian gauge theory interacting with fermions are presented. Dimensional regularization and the t Hooft minimal subtraction scheme are used. The method of calculation is described in detail. The renormalization group function $gamma_m$ determining the behavior of the effective mass of fermions is presented. The anomalous dimensions of fermions for QED and QCD up to three loops are given. All calculations were performed on a computer with the help of the SCHOOONSCHIP system for analytical manipulations. The present text was published in 1982 as a JINR Communication, JINR-P2-82-900 (in russian).