0

I have my own domain, i.e mydomain.com and own email [email protected] from which I can send email by php script. I also have custom gmail address (from google apps) [email protected] and can login go gmail email panel and can send email from that gmail account.

What usually happens are: 1) I send email (sender: [email protected]) from my domain by php script and also send email (sender: [email protected]) from gmail (google apps).

2) All email comes to [email protected] are received in gmail account, not in domain's webmail.

For this reason, I created the SPF record in Advanced DNS management of my domain as below:

v=spf1 mx a:google.com ~all

Now when I send email from my domain (by php script using smtp) to [email protected], I found SPF: pass in header of the sent mail.

But while I send email from gmail account to [email protected], I found SPF:softfail in header of the sent mail.

What will be the correct syntax of SPF record by which both the email sent will be passed the SPF, sent from my domain and gmail account.

1

2 Answers 2

3

From here: https://support.google.com/a/answer/178723

v=spf1 include:_spf.google.com ~all

Allowing me to use Gmail to send From: [email protected] with SPF=pass

1

Best way is to include Google's own SPF record:

v=spf1 mx include:gmail.com ~all

You are currently using an A-record lookup to the google.com domain, which does not corresponds to IP addresses of their actual SMTP servers.

1
  • Does that mean anybody who uses Gmail can pretend to send from mydomain.com without any SPF warnings?
    – paddy
    Mar 19, 2014 at 3:55

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.