Response status codes are not errors per-se, they are logged to the access log. They are for the clients. Errors is reserved for server-side errors, like problems in middlewares.
That makes sense, and I can understand the split between client and server errors.
I would argue the current behavior is not very intuitive. Especially coming from nginx where 404s are logged to error.log by default. I think the bigger issue here is that the config suggests the opposite of what happens:
errors error.log {
404 404.html
}
I think if you ask most people to parse that (who are not familiar with Caddy), they’d come to the conclusion that 404s would be included in the error.log.
https://caddyserver.com/docs/errors doesn’t currently address this behavior, and near the top where it talks about logging “error responses (HTTP status >= 400)” to the error log, it suggests (to me) 404 will be logged.
I’m guessing the behavior won’t be changing at this point, so I’d humbly suggest clarification in the doc, perhaps just a sentence or two similar to your reply above would help others out.