The possession of "Indecent and obscene material such as pornographic books, magazines, films, videos, DVDs and software" is prohibited in Botswana. Possession or import of such material is illegal and punishable by a fine or up to 4 years imprisonment.
In Egypt, it is illegal to distribute pornography. The possession and import of pornography are offences. Unlike numerous African nations which have no laws against child pornography, Egypt blocks child pornography websites and dealing in child pornography carries a minimum sentence of five years and fines of US$29,000. In 2009 Egypt's Administrative Court ruled that internet pornography should be banned, describing it as “venomous and vile”. In 2012 the country’s Prosecutor General ordered government ministries to block the websites, and the Administrative Court repeated its order for the Cabinet to block pornographic websites in 2015. However, the cost of blocking large numbers of pornographic websites has prevented the full implementation of the court's ruling. Egypt has the highest viewing figures for pornography in the Middle East according to a survey of access to Pornhub.
In 2004 Morocco introduced severe punishment for promoting pornography. Producing pornography of any kind is illegal in Morocco. However it does not apply much on Internet pornography, porn websites are accessible in Morocco.
Nigeria has no national laws prohibiting pornography, although the public display of graphic sexual material is illegal in Lagos. The country has a small indigenous pornography industry which produces exclusively heterosexual pornography as homosexual activity in Nigeria is illegal. Some Muslim politicians in the national government have proposed a nationwide block on pornographic websites. There is significant piracy of pornography in Nigeria, with pirated pornographic DVDs being sold from roadside stalls in Lagos. Pornography is also sold in Nigerian sex shops and some pornographic magazines are produced in the country, often reproducing pictures from foreign magazines. The first officially acknowledged hardcore pornographic film produced in Nigeria was Better Lover Valentine Sex Party. It was not submitted to the National Film and Video Censors Board for classification and it was immediately banned on the grounds of obscenity and immorality. Internet pornography is widely viewed in Nigeria. In 2015 the monthly average for the number of searches for pornography was 135,000, and in December 2014 and 2015 the proportion of searches for pornography (relative to other searches) was higher in Nigeria than in the United States. In 2013 Nigeria ranked second globally for Internet searches for gay pornography. Nigeria has the highest number of Internet pornography viewers of any country in Africa.
Pornography rated X18 is permitted by the law only if sold to persons over the age of 18 in registered stores. It is an offense to host a pornographic web site in South Africa because of the difficulty of age-verification and the requirement that pornography only be distributed from designated, licensed physical premises. It is also unlawful to visually represent bestiality (also rated XX), but not in text descriptions. Supplying violent pornography is an offence in any form, but the law allows the production of pornography that is not prohibited.