// Step 1: convert the string to an array using the str_split function $array = str_split($your_string); // Step 2: loop through the newly created array foreach ($array as $char) { echo $char; }