To get Nginx to log in JSON format you have to add the following to “nginx.conf” under the http bit: log_format json '{ "@timestamp": "$time_iso8601", ' '"message": "$remote_addr - $remote_user [$time_local] \\\"$request\\\" $status $body_bytes_sent \\\"$http_referer\\\"