Use failsafe encoding (base64) and correct index