Setting Up Null MX Records
Table of Contents
- Prerequisites
- Step-by-step instructions
- What happens after setup
- Testing null MX records
- Removing null MX records
- Common issues and troubleshooting
- Best practices
- Related topics
- Have more questions?
Null MX records explicitly indicate that a domain does not accept email. Setting one up prevents mail servers from attempting delivery and helps protect against backscatter.
Warning
Only set up null MX records if you are certain your domain will never need to receive email. If you use email forwarding, email hosting, or might need email in the future, do not use null MX records.
Prerequisites
Before setting up null MX records:
- Confirm you do not need email: Ensure your domain will never need to receive email.
- Remove existing email services: If you are currently using email forwarding or email hosting, you need to disable those services first.
- Remove existing MX records: Any existing MX records must be removed before adding a null MX record.
Step-by-step instructions
Step 1: Remove existing email services
If you are currently using email services, remove them first:
If using email forwarding:
Remove email forwarding
- Navigate to your domain’s tab.
- Delete all email forwards.
- This will automatically remove the email forwarding MX records.
If using email hosting:
Remove email hosting records
- Navigate to your domain’s tab.
- Open the .
- Find and delete all existing MX records.
- If you used a one-click service, remove it from the section.
Step 2: Remove existing MX records
Before adding a null MX record, ensure no MX records exist:
Verify and remove MX records
- Navigate to your domain’s tab.
- Open the .
- Look for any existing MX records in the record list.
- If any MX records exist, click the delete/trash icon next to each MX record and confirm the deletion.
Step 3: Add the null MX record
Add a null MX record
- In the , click .
- Select MX as the record type.
- Configure the null MX record:
-
Name field: Leave blank or enter
@to create the record at the root of your domain (e.g.,yourdomain.com). -
Priority: Enter
0. -
Mail server: Enter
.(a single dot/period).
-
Name field: Leave blank or enter
- Click .
Note
The single dot (.) represents the root of the DNS hierarchy and is the standard way to represent “no mail server” in DNS, as specified in RFC 7505.
Step 4: Verify the null MX record
After adding the null MX record, verify it is configured correctly:
-
Check in DNSimple: In the Record Editor, verify the MX record shows priority 0 and mail server
.. -
Use dig command:
dig +short yourdomain.com MXThis should return:
0 . -
Check DNS propagation: Use online tools like whatsmydns.net to verify your null MX record has propagated globally. The record should show priority 0 with mail server
..
What happens after setup
Once the null MX record is set up and propagated:
- Other mail servers will see the null MX record and know your domain does not accept email.
- Mail servers will not attempt to deliver email to your domain.
- Emails sent to your domain will be immediately rejected or returned to the sender.
- Your domain will not receive bounce messages or non-delivery reports.
Testing null MX records
To test that your null MX record is working:
-
Send a test email: Try sending an email to an address at your domain (e.g.,
test@yourdomain.com). - Check for immediate rejection: The email should be immediately rejected or returned to the sender.
- Verify no delivery attempts: Check your domain’s DNS logs (if available) to confirm no delivery attempts were made.
Tip
You can also use online email testing tools to verify that mail servers recognize your null MX record and do not attempt delivery.
Removing null MX records
If you need to remove a null MX record (for example, to set up email forwarding or email hosting):
Remove the null MX record
- Navigate to your domain’s tab.
- Open the .
- Find the null MX record (priority 0, mail server
.). - Click the delete/trash icon.
- Confirm the deletion.
After removing the null MX record, you can set up email forwarding or email hosting as needed.
Common issues and troubleshooting
Null MX record not working
Problem: Mail servers are still attempting delivery after setting up a null MX record.
Solutions:
-
Verify the record: Use
dig +short yourdomain.com MXto confirm the null MX record is published correctly. - Check DNS propagation: Allow time for DNS changes to propagate (typically a few minutes to a few hours).
-
Verify format: Ensure the mail server field is exactly
.(a single dot), not..or anything else. -
Check priority: Ensure the priority is exactly
0.
Want to use email after setting up null MX
Problem: You set up a null MX record but now need email functionality.
Solution:
- Remove the null MX record (as described above).
- Set up email forwarding or email hosting as needed.
- Add the appropriate MX records for your email service.
Email forwarding not working
Problem: You are trying to use email forwarding but it is not working, and you have a null MX record.
Solution:
- Remove the null MX record first.
- Then set up email forwarding, which will automatically add the necessary MX records.
Best practices
Use only when needed: Only set up null MX records if you are certain your domain will never need email.
Document your decision: Consider documenting why you are using null MX records for future reference.
Monitor for issues: If you notice any unexpected behavior, verify your null MX record is configured correctly.
Plan for future needs: If there is any possibility you will need email in the future, do not use null MX records.
Related topics
- What Are Null MX Records? - Explanation of null MX records and their purpose
- What Is an MX Record? - General information about MX records
- Email Forwarding - Information about DNSimple’s email forwarding service
- Setting Up MX Records for Email Hosting - Guide to setting up MX records for email hosting
Have more questions?
If you have additional questions or need any assistance with setting up null MX records, just contact support, and we’ll be happy to help.