Urgent.News

What's breaking now, across thousands of outlets.

Tech

WordPress transactional email: the order to configure SMTP, SPF, DKIM, and DMARC

Your contact form notification and your WooCommerce order email are both sent by wp_mail() . If they land in spam, the mail content is usually not the first thing to fix. The first thing is authentication: the receiving mail server needs to know that the message really came from your domain. The order below is about avoiding rework: Decide the sending domain and the SMTP relay. Route WordPress…

To ensure your WordPress contact form notifications and WooCommerce order emails reach their intended recipients, you must configure authentication, domain routing, and email authentication protocols. First, establish the sender identity by designating reliable email addresses: the Return-Path for bounced messages, Reply-To for form notifications, and the visible From address for order emails.

Next, configure an SMTP relay before adding SPF, DKIM, or DMARC. Utilize a single SMTP path, whether through a plugin or custom code, to maintain consistency. A recommended plugin can route wp_mail() through an authenticated SMTP relay. After setting up the SMTP relay, add SPF records to authorize hosts authorized to send mail for your envelope domain.

Merge existing SPF records if necessary, and avoid publishing multiple v=spf1 records. With SPF established, move on to DKIM by publishing a DKIM record in your DNS zone, signing outgoing emails with a private key. Finally, configure DMARC to monitor and enforce the results of SPF and DKIM checks, beginning in monitoring mode. Test all email paths to confirm proper delivery before fully implementing these authentication measures.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

Help, I'm using Houdini

This is a submission for the Hacktoberfest Open-Source AI Challenge: Week 3 — Slow and Steady If you've ever used Houdini for VFX, Procedural modelling, animation or CG content creation then you're…

  • houdini-wizard tool enhances Houdini's procedural modeling and animation capabilities.
  • Real-time help documentation updates as user selects nodes in node network viewer.
  • AI model provides concise explanations based on parameter values without inventing settings.

More from Monday 26 October →