Background Although access to essential medicines means resolution for most health conditions in primary health care, ensuring it is still a complex challenge for all health systems. Recent studies show that fair access to medicines must be determined by health care needs, considering the variables in the socioeconomic environment. In this context, despite advances, weaknesses in the development of pharmaceutical services persist, strongly related to management capacity. The study investigates the relationship between the management capacity of Pharmaceutical Services and socioeconomic indices in Brazilian municipalities, analysing which contextual factors are involved in its development.Methods Data from a cross-sectional exploratory study at national scale and indicators developed by Faraco et al. were used to define the capacity of Pharmaceutical Services management. Pearson’s chi-square test and multivariate analysis were performed to associate Pharmaceutical Services management capacity with socioeconomic indices of each municipality. These socioeconomic indices were collected from public database platforms.Results The results prove significant relationships between management and socioeconomic indicators, suggesting that Pharmaceutical Services management capacity is influenced by the environment in which it operates. This study shows municipalities with better management capacity results were those with better socioeconomic indices, better health system conditions and structure, reflecting a greater number of professionals, greater participation of popular social control and use public resources. It is also highlighted that municipalities with a smaller population size and lower socio-economic indices have less ability to manage pharmaceutical services, revealing worsening inequalities for its citizens.Conclusions The existence of an adequate minimum structure, a qualified workforce, service organization, and opportunities for political articulation are essential, as well as conditions for these municipalities to develop and improve their management capacity and for financing based on socioeconomic indicators to become an effective access and adequate use of medicines for the population.