sleep for 1 sec php code example Example 1: php sleep half a second usleep(500000); Example 2: sleep php <?php sleep(4); echo "Done\n"; ?>