The following command run on illumos with the real sendmail gets sendmail to add a Message-Id header. echo "To: me@example.net\nSubject: test" | sendmail -ti If I run this command (on Alpine Linux) with the Busybox sendmail it does not add a Message-Id header. (BusyBox v1.35.0 (2022-11-19 10:13:10 UTC) multi-call binary.) echo -e "To: me@example.net\nSubject: test" | sendmail -ti Unfortunately, gmail does reject mails without a Message-Id. And, although the RFC violation seems to be with Google, I would suggest that the Message-Id header is added as it would increase compatibility with real sendmail and serve better for the intended purpose (sending mails as easy as possible).
I just noticed that msmpt added the same feature request recently https://github.com/marlam/msmtp-mirror/issues/82