On most ordinary servers, these daemons (apache, nginx, etc.) do not have a real "home directory".
If you consider "shared hosting", this would be impossible, since there can only be one home directory per user, but many vhosts per daemon.
I assume that you are looking for the ist environment variable DOCUMENT_ROOT (the root directory for current vhost documents).
$_SERVER['DOCUMENT_ROOT']
kwood source
share