Background: Chronic pain and poor sleep quality are biopsychosocial changes that are associated with human aging and have a bidirectional correlation. The objective was to evaluate the association between chronic pain and quality of sleep and quality of life of elderly people. Methods: This was a cross-sectional study with a correlational quantitative approach on the association of chronic pain with the quality of sleep and quality of life of elderly people in the community. The evaluation was carried out using sociodemographic, clinical and anthropometric questionnaires, Pittsburgh Sleep Quality Index, visual analogue scale, cognitive impairment, quality of life, and functional mobility. Descriptive statistical analysis was performed. The means between the groups were compared using the Student’s t-test for independent samples, using the Spearman correlation coefficient (ρ) to test the associations and one-way analysis of variance to compare the means between the three age groups. Results: This study included 131 elderly people, predominantly female (87%), with an average age of 68 ± 7 years, low income per capita (84.8% ≤2 MW), and low education (86.3% ≤3 years of study). The elderly with a history of chronic pain had worse quality of sleep and quality of life than those without chronic pain. There was a moderate (ρ = 0.590) and significant (p <0.01) positive correlation between sleep quality and chronic pain intensity, and a moderate (ρ = -0.57) and significant (p <0.01) correlation between quality of life and the intensity of chronic pain. Conclusion: Elderly people with chronic pain have worse quality of sleep and quality of life than those without chronic pain. We also found that the greater the number of chronic diseases, the worse the quality of sleep and quality of life. Trial Registration: Registro Brasileiro de Ensaios Clínicos (REBEC) Identifier: RBR-3cqzfy Keywords: Elderly; sleep; chronic pain; quality of life.