Search Results
microtime () returns the current Unix timestamp with microseconds. This function is only available on operating systems that support the gettimeofday () system call.
Definition and Usage The microtime () function returns the current Unix timestamp with microseconds.
Jul 11, 2025 · The microtime () function is an inbuilt function in PHP which is used to return the current Unix timestamp with microseconds. The $get_as_float is sent as a parameter to the microtime () function and it returns the string microsec sec by default.
The microtime() function returns the current Unix timestamp with microseconds. By default, this function returns a string value which contains microseconds and seconds separated by space (msec sec).
Learn how to use PHP's microtime () function to measure the execution time of your scripts and optimize their performance.
Dec 29, 2025 · The PHP microtime function is the one that returns the current Unix timestamp with microseconds. And interestingly, you can use the said function to get time in other units as well, such as seconds. So, here you’ll see how the PHP microtime works, how you can use the same for converting time units, and which other function returns time in seconds.
People also ask
What is a PHP Microtime function?
What is a Microtime function in Unix?
How to return Unix timestamp with microseconds in PHP?
What is a Microtime float in Unix?
Aug 19, 2022 · The microtime() function creates current Unix timestamp with microseconds values.
