I created a basic Sparkpost account and am trying to connect it to Craft to send email notifications.

When I click the 'test' button in Craft, I get "there was an error testing your email settings", but there is nothing like [exception.Craft\EmailTestException] in the logs. https://craftcms.com/knowledge-base/troubleshooting-email-errors

Note: password is the API key.

EDIT: The problem was simple, my credentials were incorrect - also, only port 587 worked with my set up, the alternate port did not. Please note, the error logs for this (craft/storage/logs/web.log) are not very helpful. Best to triple check credentials and settings.

1 Answer 1


Without any logs it's tricky to know where the issue is, have you confirmed that outbound SMTP ports 25, 465, 587 are open to send email? Are you running this on your local development environment or a hosting provider environment?

Make sure you are running with dev mode on, so you can see verbose information in the logs and full stack trace errors. The knowledgebase article you linked might be a bit misleading as I believe it's referring to the error output from a Craft CMS 2 website, not a Craft CMS 3 site.

The log file you need to look at is /storage/logs/web.log. When debugging is enabled, this file gets very verbose quickly. The best thing would be to completely clear it out and then do your SMTP test to see the specific error occurring without having to scroll through a lot of verbose info.

Equally are there logs on your SMTP providers side when you attempt to perform an SMTP request from Craft CMS? I'd guess not, given Craft CMS is throwing an error, but just in case it's at least making a negotiation to the SMTP server.

  • Thanks James. I did further troubleshooting and got it to work.
    – 4midori
    Commented Jul 2, 2022 at 20:00
  • @4midori Awesome. For the benefit of other, it would be great if you updated your post with the issue and solution to help others in the future. Commented Jul 3, 2022 at 19:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.