Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3938456
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T00:11:13+00:00 2026-05-20T00:11:13+00:00

I just started offering user accounts on my website (large PR6 site, with a

  • 0

I just started offering user accounts on my website (large PR6 site, with a good reputation) and I noticed that the registration emails almost always go to the receivers spam box.

So far we have only sent out a few emails, so its not like we’ve been slamming out thousands.

I send the emails via PHP with the mail() function. Below you can find the headers that i send with the mail() function.

$headers  = 'MIME-Version: 1.0' . "\r\n";
$headers  .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
$headers  .= 'From: Domain.com <noreply@mydomain.com>' . "\r\n";

Is there a way, or a trick to get round these spam filters? Its clearly not spam what I am sending out. The registration email contains 3 links.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T00:11:13+00:00Added an answer on May 20, 2026 at 12:11 am

    There are many things that can cause emails to be flagged as spam. The solution is twofold: On one hand you should be using a good smtp server (deliverability) and then you should be forming your emails correctly. (A daunting task using mail().)

    Sending emails correctly using PHP

    You should really use something like PHPMailer. It’s a php library for sending emails and does them properly, so the emails have a higher chance of reaching correctly.

    http://phpmailer.worxware.com/

    Email delivery

    Email delivery can be a headache, but I can recommend http://www.sendgrid.com – You basically set them up as phpmailer’s smtp server and use their outgoing mail server.. They’re experts in email deliverability and you’ll have a much easier time. Especially when you start sending out hordes of emails.

    Code example

    Example email from phpmailer’s website:

    <?php
    require_once('../class.phpmailer.php');
    
    $mail             = new PHPMailer();
    
    $mail->IsSMTP(); // telling the class to use SMTP
    $mail->SMTPDebug  = 2;  // enables SMTP debug information (for testing)
                                           // 1 = errors and messages
                                           // 2 = messages only
    $mail->SMTPAuth   = true;                  // enable SMTP authentication
    $mail->Host       = "smtp.sendgrid.net"; // sets the SMTP server to sendgrid's server
    $mail->Port       = 25;                    // set the SMTP port for the GMAIL server
    $mail->Username   = "emailuser@host.com"; // Sendgrid user
    $mail->Password   = "yourpassword";        // Sendgrid passw.
    
    $mail->SetFrom('name@yourdomain.com', 'First Last');
    
    $mail->AddReplyTo("name@yourdomain.com","First Last");
    
    $mail->Subject    = "PHPMailer Test Subject via smtp, basic with authentication";
    
    $mail->AltBody    = "To view the message, please use an HTML compatible email viewer!"; // optional, comment out and test
    
    $mail->MsgHTML($body);
    
    $address = "whoto@otherdomain.com";
    $mail->AddAddress($address, "John Doe");
    
    echo !$mail->Send() ? "Mailer Error: " . $mail->ErrorInfo : "Message sent!";    
    ?>
    

    I’d like to say that I’m not affiliated with Sendgrid in any ways. I’m just a big fan of their service. I fought with mail() function, smtp servers, mail queues and services for many years in web dev shop and I do not wish that fate for my worst enemy. Save yourself some time and worries.

    Cheers…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Have just started using Google Chrome , and noticed in parts of our site,
Just started a site and I have an /img directory on the main domain.
Just started a site and I have an /img directory on the main domain.
Just started using Java (for Android, if that matters) and all I want is
Just started getting a bunch of errors on our C# .Net app that seemed
Just started to get my feet wet with C# and .NET, liking it so
Just started with JQuery and I've managed to pass a parameter using POST, firebug
Just started my first MVC 2.0 .net application. And I set up some default
Just started working with .NET and MVC(1). I'm having a problem wherein in my
Just started coding in AS3 with FlashDevelop and coming from a C# background, I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.