Sample code for 30+ languages & platforms
Chilkat2-Python

Decode Base64

Demonstrates how to decode base64.

Chilkat Chilkat2-Python Downloads

Chilkat2-Python
import chilkat2

success = False

bd = chilkat2.BinData()

# Append a base64 string to bd.
success = bd.AppendEncoded("c2VjcmV0","base64")

# The bd now contains the decoded bytes.
# Let's say it was a password string..
password = bd.GetString("utf-8")

# Decodes to "secret".
print("password = " + password)