Posted on June 14, 2021 by winnieHow To Convert Object To An Array in PHP 1. Typecasting Object to Array PHP $array = (array) $object; 2. Using the JSON Decode and Encode Method json_decode(json_encode($object), true);