A comparative analysis of the state of drug-related crime in penitentiary institutions and at the national level is carried out. The author identifies the main determinants that led to a sharp increase in the number of criminal offences committed in penitentiary institutions related to illicit trafficking in narcotic drugs, psychotropic substances, their analogues and precursors. The author establishes that one of the main factors of the spread of drug-related crimes on the territory of the mentioned institutions is the possibility for convicts and persons taken into custody to illegally use mobile communications and the Internet to establish communication with criminal groups outside the institution engaged in the manufacture and distribution of narcotic drugs and psychotropic substances. Among the main factors of the sharp increase in the quantitative indicators of drug crimes and their prevalence in penal institutions are the concentration of a significant number of people who consume and distribute narcotic drugs and psychotropic substances, as well as the growing prevalence of synthetic narcotic drugs. The conditions that contribute to the spread of criminal offenses of this type include the detention of convicts in multi-bed dormitories, inadequate equipment of institutions with engineering and technical means of preventing the entry of prohibited substances into institutions for the execution of punishments. Based on the results of the research, the author came to the conclusion that in the last five years there has been a significant increase in the number of criminal offenses related to narcotic drugs and psychotropic substances, committed by groups of persons. This trend indicates the growing organization and scaling of this type of crime. The existence of criminal integration links and interdependence of drug crime at the national level and in institutions of execution of punishments is substantiated. Key words: convicts, deprivation of liberty, criminal offense, narcotic drugs, psychotropic substances, dynamics of drug crime, crime prevention, staff of penal institutions.