You can’t specify your own format, but in nginx build-in several level’s of error_log-ing.
Syntax: error_log file [ debug | info | notice | warn | error | crit ]
Default: ${prefix}/logs/error.log
Specifies the file where server (and fastcgi) errors are logged.
Default values for the error level:
- in the main section – error
- in the HTTP section – crit
- in the server section – crit
In my error_log, time always presented int begin of each error string in log.