Header location method return to original page php code example Example: php previous site header('Location: ' . $_SERVER['HTTP_REFERER']);