The prisoners are to be released within 72 hours.
Prisoners serving time for murder, rape or other serious crimes, as well as those jailed for crimes against state security, will not be released.
On September 19, Pope Francis will become the third pope to travel to Cuba. He will then travel to the United States.
The pope acted as an intermediary in talks between the two neighbouring states that lead to the re-establishment of diplomatic relations.
More about: