NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
Go modules, #1313 by repository stars
Latest stable
v0.8.2
Last release 12 days ago
08 Nov 2026
Release timing varies
gaps range from 8 days to 5 months
Nearly every release is documented
notes for 48 of 48 stable releases
Nothing withdrawn
no release was ever pulled
5 years old
237 releases · first in 2022
Drag across the ruler to compare, or tap a release to open it.
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Welcome to go-mail v0.5.2! This release is mainly a maintenance release.
Welcome to go-mail v0.5.2! This release is mainly a maintenance release.
With #341 we introduce support for the fig.StringUnmarshaler interface for SMTPAuthType. This allows users of fig to reference the mail.SMTPAuthType directly in their fig config.
The PR #344 introduced two new SMTPAuthType types: SMTPAuthPlainNoEnc and SMTPAuthLoginNoEnc. Both allow PLAIN and LOGIN authentication over unencrypted connections. This can be useful if the connection has already been secured in a different way (e. g. a SSH tunnel).
The PRs #348, #349 and #352 are a full overhaul of the go-mail test suite. Almost all tests have been rewritten to better coverage, visibility and maintainability. We've now covered +92% of all code. The Github workflow was also improved and is now less error prone.
During the tests rewrite a couple of minor bugs were found and fixed on the way:
Full Changelog: v0.5.1...v0.5.2
Welcome to go-mail v0.5.2! This release is mainly a maintenance release.
With #341 we introduce support for the fig.StringUnmarshaler interface for SMTPAuthType. This allows users of fig to reference the mail.SMTPAuthType directly in their fig config.
The PR #344 introduced two new SMTPAuthType types: SMTPAuthPlainNoEnc and SMTPAuthLoginNoEnc. Both allow PLAIN and LOGIN authentication over unencrypted connections. This can be useful if the connection has already been secured in a different way (e. g. a SSH tunnel).
The PRs #348, #349 and #352 are a full overhaul of the go-mail test suite. Almost all tests have been rewritten to better coverage, visibility and maintainability. We've now covered +92% of all code. The Github workflow was also improved and is now less error prone.
During the tests rewrite a couple of minor bugs were found and fixed on the way:
Full Changelog: https://github.com/wneessen/go-mail/compare/v0.5.1...v0.5.2
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Welcome to go-mail v0.5.1! This release brings a bug fix and some optimizations around logging.
Welcome to go-mail v0.5.1! This release brings a bug fix and some optimizations around logging.
With v0.5.0 we unintentionally introduced a regression for the SMTP authentication part of go-mail - at least for some edge cases. As reported in #332, in case the user did not provide an explicit SMTP authentication option, the Client would fail with an "server does not support SMTP AUTH" error. The quick work-around was setting SMTP Auth to "Custom" as pointed out in #328. While it improved the security of the package, as it would not skip authentication if none was given, it was breaking in some edge cases and the "Custom" auth type was not meant to be the default.
We now changed the SMTPAuthNoAuth from an empty string to "NOAUTH". This value is set as default for the Client in NewClient. This way we always have a fixed assignment and an empty string would not skip authentication. The auth() method has been updated to either assign the smtp.Auth function if SMTPAuthType is not set to "NOAUTH" or skip the part there is already an auth function set (this would only happen when SetSMTPAuthCustom or WithSMTPAuthCustom were used).
If SMTPAuthType is set to an empty string, the authentication assignment would fail as it is a not supported mechanism, therefore making sure that the client wouldn't accidentaly skip the authentication at all.
We are sorry if this broke your code with the v0.5.0 release. Thanks to @james-d-elliott and @ugexe for reporting this and for testing the fix.
go-mail claims to ship with sane defaults. While this is true, there was one aspect where this wasn't true: debug logging. The debug logger would potentially expose SMTP authentication data to the logs, which could pose a risk. With v0.5.1 we now redact SMTP authentication data by default as a sane and secure default. We realize though, that you sometimes need access to the authentication data. Therefore two new options were introduced to the Client: WithLogAuthData() and SetLogAuthData(bool). With either of these you can instruct the Client to log full SMTP authentication data again.
As pointed out by @mitar in #326, the way we generated the message ID was much to complicated using different sources of randomness while already using a secure string generator. #329 simplied the message ID generation to only use the secure string generator and get rid of the rest of the strings and numbers we added to the message ID. We now have 64 possible characters to generate a 22 character long string, which provides approx. 132 bits of entropy. This should more than enough to guarantee a unique ID for each message.
Full Changelog: https://github.com/wneessen/go-mail/compare/v0.5.0...v0.5.1
Nothing published for this version
Nothing published for this version
Nothing published for this version
Welcome to go-mail v0.5.0! This release is a big one, bringing new features and improvements to the go-mail codebase!
Welcome to go-mail v0.5.0! This release is a big one, bringing new features and improvements to the go-mail codebase!
With #307 we've made go-mail goroutine-safe by introducing a sync.Mutex. Concurrency-safety was a much requested feature, now allowing you to dial your Client and then use that Client in different goroutines. While we've added a lot of new tests (including a test SMTP server to which we connect to in different goroutines), this feature has not been extensively tested in an production environment. Therefore we've marked this features (and respectively this release) as a potentially breaking release. If you plan to use go-mail in a concurrency scenario, please test properly and report back any issues.
With #310 we have introduced SMTP authentication functions for SCRAM-SHA-1(-PLUS) and SCRAM-SHA-256(-PLUS). Most of the ground work was contributed by @drakkan. @wneessen cleaned up the code a bit, added channel bindings support and added several test cases.
SCRAM-SHA-X(-PLUS) isn't commonly supported, yet but I've tested the code with Dovecot (no channel binding support) and mox (supports both) and the code seems to be working properly. Feedback from using SCRAM with other systems is appreciated!
Thanks again to @drakkan for the excellent WIP code.
With #301 the error handling was refactored in accordance to #168. Errors are not nested into each other anymore. The send logic for a single message has been moved to the non-version-specific Client.go while the version-specific only handle multi-message handling and error combination. Error messages now also refer to a message ID of the message that failed (if present), for easier debugging.
Thanks to @mitar for pointing out the flaws in the old error handling system and for suggesting the improvements.
With #312 we've refactored the SMTP LOGIN auth handling, to improve compatibility with various server responses.
In detail: before, we were only roughly following the Microsoft Spec they defined for MS Outlook. Meaning:
This is the common approach for most mail systems/providers and is the specified way by Microsoft in their MS-XLOGIN spec.
Yet, there is also an old IETF draft for SMTP AUTH LOGIN that states for clients:
The contents of both challenges SHOULD be ignored.
Since there is no official standard RFC and we've seen different implementations of this mechanism (sending "Username:", "Username", "username", "User name", etc.) we now follow the IETF-Draft instead and ignore any server challange to allow compatiblity with most mail servers/providers. This way it works with servers that follow the Microsoft way but also any other kind of implementation (like i. e. Mox).
With #324 we revises the GoDoc documenation comments for the whole package. It provides much more details for each method in a more standardised format, allowing users of the package to get better information on what does what. This is especially helpful for LSP implementations like gopls.
The random methods for generating random numbers have been simplified and the use of crypto/rand has been replaced by math/rand or math/rand/v2 (depending on the used Go version). We've realized that for our use cases, math/rand will provide enough randomness. It simplies the randNum code a lot.
So far, we were always commited to keep go-mail dependency-free, meaning only relying on the Go Stdlib. So far this has been working well and we believe that people appreciate that no further dependcies are added to their project, when they import go-mail. Yet, we've finally reached a point, where adding new features might require us to import some limited dependencies. This happened with the SCRAM support in #310. We've done a poll beforehand to see if the community is fine with this and the common agreement is, that people are ok with a limited, well curated list of external packages as long as the packages are still maintained and have a good security reputation. Therefore this release adds the first dependencies to go-mail - both from the Go extended library:
golang.org/x/cryptogolang.org/x/textAs your codebase might not allow for additional dependencies, this feature is also marked as Potentially breaking
We hope you like this release and a big thanks goes out the community that contributed to this release.
Full Changelog: https://github.com/wneessen/go-mail/compare/v0.4.4...v0.5.0
Nothing published for this version
Nothing published for this version
Nothing published for this version
This release is identical to v0.4.3. Nothing changed. Due to an unfortunate misclick on my end, v0.4.3 was released twice which caused a checksum mism
This release is identical to v0.4.3. Nothing changed. Due to an unfortunate misclick on my end, v0.4.3 was released twice which caused a checksum mismatch for some users. This release fixes the issue by releasing as a new tag.
Sorry for the inconveniences this caused.
Full Changelog: https://github.com/wneessen/go-mail/compare/v0.4.3...v0.4.4
Nothing published for this version
Nothing published for this version
Nothing published for this version
Welcome to go-mail v0.4.3! This is mainly a maintenance release introducing some minor fixes and improvements. I want to go back to tighter release sc
Welcome to go-mail v0.4.3! This is mainly a maintenance release introducing some minor fixes and improvements. I want to go back to tighter release schedule, so the users that provided PRs don't have to wait too long for their PRs to make it into a release.
I want to thank @NorbertHauriel, @alfa-alex and @lipangeng for their contributions to this release!
Full Changelog: https://github.com/wneessen/go-mail/compare/v0.4.2...v0.4.3
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
…previously set ports. Additionally, the deprecation notes have been removed and replaced with notes on best-practice recommendations, referring the ne…
This release of go-mail brings some new features as well as some code clean up and stability improvments.
With #145 / #249 a new parsing feature has been added to go-mail which allows the user to parse generic EML files into a go-mail Msg struct. This is helpful if you have a already sent mail and want to re-use it with go-mail. Three new public methods have been added: EMLToMsgFromString, EMLToMsgFromReader and EMLToMsgFromFile, allowing the user to parse the EML from different sources.
Caveat: Even though I put lots of efforts into testing this new feature and I am certain that most cases should work without issue, emails are still a complex topic with lots of written and unwritten standards. There might be some special cases in which the parsing might be off. In this case, please raise an issue with an example of the mail, so that I can have a look.
The SMTPAuthNoAuth AuthType has been added as convenience feature. It is equivalent to performing no authentication at all. It can be used for mail servers that do not support/require authentication. It is still advised to use the Client without the WithSMTPAuth option, instead.
When I started go-mail, I was following the Go best practices document, choosing mostly single-character variable names. Looking at the code base size of go-mail and considering how many people work with the code base and actually contribute to the project now, I think this was the wrong decision, as it makes it hard for contributors to follow the code - especially given that I have not followed the recommendation of using more descriptive variables names for global context variables. Therefore with #182 I've refactored all variable names for better readability.
Note: The code in the smtp/ directory has been left untouched so that syncing with the upstream stdlib is not made more complicated than it has to be.
It has been pointed out in #181 that the changes to the default ports and fallback ports wasn't well thought through. With #207 this behaviour has been reworked. The clients' functions WithSSLPort, WithTLSPortPolicy, SetTLSPortPolicy, and SetSSLPort were revised to avoid overriding previously set ports. Additionally, the deprecation notes have been removed and replaced with notes on best-practice recommendations, referring the new *Port() methods.
With #178 and option to skip the setting of the User-Agent has been added. This option is suitable for scenarios like SMTP proxies where headers are conditionally passed based on receipt. Thanks a lot to @gegorov2030 for their contribution!
Full Changelog: https://github.com/wneessen/go-mail/compare/v0.4.1...v0.4.2
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
One column per quarter.