handle php serialize in python Install pip install serialize-php Usage import php_serialize php_serialize.dumps(...) php_serialize.loads(b'...')