San Pedro is the biggest prison in La Paz, Bolivia, but not all of the residents are criminals.
The government only funds basic food for the inmates at San Pedro; beyond that, the inmates have to earn money to survive. Because family members often can't afford to live elsewhere, many actually live with their inmates in the prison.
In these situations, everyone works together for income and the prison's economy actually functions well as something of a black market. The sale of drugs to visiting tourists is a common practice, and it gives those inside a significant income and an unusual amount of freedom within the prison walls.
San Pedro is kind of like a different country with its own rules, traditions and laws. Each division of the prison is run like a separate government, with elected leaders charging taxes and providing for the greater population. There are approximately 1500 inmates and that is without counting the many families who also live in the prison.
There are different types of cells, and they can be rented for different prices and different time periods as if they were small apartments. It is quite easy to find a place to play poker, pool, chess etc. The restaurants are also owned by the inmates. There is also a church and a hospital within the prison. Around 80% of the prisoners are serving their time for drug dealing. The police rarely enter the prison, even though around 4 prisoners die every month.
Every Prisoner is also allowed to vote in the national Bolivian elections. Politicians visit the prison to increase their support for future elections. Most prisoners have jobs such as hairdressers and shopkeepers. Cocaine is produced in large laboratories. The drug is often exported outside of the prison.
Laws are developed by inmates and there is little tolerance for those who have committed crimes against women or children.