Speaking to bishops from Tanzania last week, Pope Francis praised church workers in Africa “who strive diligently to educate people in the area of sexual responsibility and chastity” with the aim of preventing HIV and AIDS. Sub-Saharan Africa is home to more than two-thirds of the world’s people living with HIV, according to amfAR, The Foundation for AIDS Research.

Many in Africa see use of contraception as immoralWhile Francis didn’t specifically refer to condom use, his predecessor, Pope Benedict XVI, once said that condoms can “increase the problem” of HIV and AIDS by encouraging promiscuity. Roman Catholic Church teaching rejects the use of artificial contraception on a moral basis.

Several African nations stand out among the most conservative on the issue of contraceptive use, according to a recent Pew Research Center survey of people in 40 countries. Nigeria, Ghana, Uganda, Kenya and Senegal ranked among the nine countries with the most moral opposition to contraception.

In Nigeria and Ghana, roughly half or more of each population said that contraceptive use is morally unacceptable (54% and 52%, respectively). Out of the 40 countries surveyed, only Pakistan (65%) had a higher rate of opposition.

There is less moral objection to contraception in the other sub-Saharan African nations in the survey, but significant shares in Uganda (38%), Kenya (33%) and Senegal (28%) said contraceptive use is morally wrong. The comparable figure for the U.S. is 7%.

South Africa, which has more people living with HIV/AIDS than any other nation, stands out in sub-Saharan Africa for its lower level of moral opposition to contraceptive use. Just 15% of South Africans said contraception is morally unacceptable, while fully two-thirds (68%) said it is morally acceptable. A study published in 2012 by the British Royal Society found that increased condom use was the “most significant factor” in slowing the spread of HIV in South Africa.

Explore attitudes in countries around the world with our Global Views of Morality interactive.

Michael Lipka  is an associate director focusing on news and information research at Pew Research Center.