HTML image elements have this simplified format:
That something can be data-uri, for example:
Correcting JRodDynamite's post:
from base64 import decodestring png_arr= "data:image/png;base64,iVBORw0KGg..." png_arr = png_arr.split(",") png_arr = png_arr[1] fh = open("imageToSave.png", "wb") fh.write(decodestring(png_arr)) fh.close()