In this article, we’ll discuss the methods to build a free SMTP server. We’ll list some of the free open-source software or email marketing tools. You’ll also find out how to set up SMTP using postal and fully-featured open-source mail. Finally, we’ll provide you with a brief overview of <\/p>\n\n\n\n
In this process, we can use postal a free delivery platform. Because it has many consequences providing all the tools and features to set up a free SMTP server to send unlimited emails<\/a>. <\/p>\n\n\n\n
You should use the postal because of the following consequences:<\/p>\n\n\n\n
SMTP stands for \u201cSimple Mail Transfer Protocol\u201d is the medium, which specifically triggers the process of email deliverability with full care. The SMTP server is the delivery agent responsible for the delivery of each email through the medium (internet) with full care. But in contrast, it has the authority to pass or deny the delivery of emails over the internet therefore, first of all, you have to configure the right SMTP setting and addresses. Besides every marketing email system works with agents:<\/p>\n\n\n\n
The sender<\/strong>: which allows you to send an email over the internet.<\/p>\n\n\n\n
The management application<\/strong>: its function is to arrange, monitor, and analyze the consequences and manage your mail server later. <\/p>\n\n\n\n
To run the marketing system we need both to work simultaneously and properly. Meanwhile for email marketing, you need to send unlimited email without any restrictions by companies or monthly plans or other. <\/p>\n\n\n\n
Now, get ready to build the SMTP server. I\u2019ll show you how to how to set up the server step by step.<\/p>\n\n\n\n
To build the Server, you need two things:<\/p>\n\n\n\n
If you are ambitious to send an email then first you have to select an email domain like this one:<\/p>\n\n\n\n
mail@servicesground.com\/blog<\/em><\/strong><\/p>\n\n\n\n
In the above email, you can see the \u201cservicesground.com\/blog\u201d is the domain. The same kind of domain you are required to send an email from your SMTP server.<\/p>\n\n\n\n
Usually, the website domain name should be used but in case of a cold email campaign, you should avoid using a business domain to keep it safe from the blacklist. If you don\u2019t have any domain then you have to get it first to continue the setup.<\/p>\n\n\n\n
How to get a domain? <\/p>\n\n\n\n
There are a lot of DOMAIN REGISTRATION PROVIDERS to get a domain and it cost just 10$ per year. <\/p>\n\n\n\n
You can get a domain from:<\/p>\n\n\n\n
The second thing you require to setup SMTP is a VPS server<\/a>.<\/p>\n\n\n\n
If you don\u2019t have a VPS server<\/a> then first, you\u2019ve to buy it from the Web hosting or Cloud Services Company, available for public with a public IP. The function of the VPS server is to drive the website efficiently and then run the machine in the cloud to do the desired tasks. After getting the server make sure that its port 25 must be opened because through this port server can communicate over the internet. <\/p>\n\n\n\n
In computing, all servers have a firewall running which then blocks all the ports except the one you need. To use a certain port you need to open that port in the firewall. Basically, a firewall is the network security system that controls the traffic moving over the internet by creating a barrier between the trusted and untrusted network. How the firewall works the following diagram will clear your all doubts.<\/p>\n\n\n\n
After getting the server make sure that port 25 is allowed by the company because some companies block this to protect from spammers used to send emails.<\/p>\n\n\n\n
Here is a list of some companies that allows port 25.<\/p>\n\n\n\n
You can also start with (Contabo<\/a>) which is the cheapest VPS service or sign up on the (DigitalOcean<\/a>) which offers 100$ in order to test everything.<\/p>\n\n\n\n
After selecting the VPS Company, create a VPS server<\/a> according to the following specification:<\/p>\n\n\n\n
Now get ready to prepare the VPS server step by step. Using an SSH client like putty or bitwise make a connection with your server. <\/p>\n\n\n\n
hostname \u2013f<\/code><\/pre>\n\n\n\n
- If you don\u2019t get a form like Anything.Domain.com then change your hostname by using the following command:<\/li><\/ul>\n\n\n\n
sudo hostname host.domain.tld<\/code><\/pre>\n\n\n\n
- Where host can be anything you want so let\u2019s say the domain name for this tutorial is example.com<\/li><\/ul>\n\n\n\n
sudo hostname postal.example.com<\/code><\/pre>\n\n\n\n
Map Your Domain Name<\/strong><\/h3>\n\n\n\n
As you set your VPS server & its domain name, subsequently go to the domain provider and map it to the VPS server<\/a>. Then open the DNS management zone and add a new record to it like this:<\/p>\n\n\n\n
<\/figure>\n\n\n\nIn this article I\u2019ll use server and you can choose whatever you want<\/p>\n\n\n\n
Setup Free SMTP Server<\/strong><\/h3>\n\n\n\n
If the VPS is ready then you can start the installation process so, for this, you have to install SMTP software. <\/p>\n\n\n\n
Install Postal Free SMTP Software<\/strong><\/h3>\n\n\n\n
You can have several SMTP software like PowerMTA, Postal, Exim, Postfix, or other suitable for you. But we\u2019ll use Postal as our SMTP software in this tutorial. As you know, we have selected Contabo<\/a> so, we\u2019ll need to run the following command before initiating the process:<\/p>\n\n\n\n
sudo apt-get install apt-transport-https<\/code><\/pre>\n\n\n\n
To Install Postal<\/strong>, simply run this command on your server:<\/p>\n\n\n\n
curl https:\/\/raw.githubusercontent.com\/atech\/postal\/master\/script\/install\/ubuntu1604.sh | sh<\/code><\/pre>\n\n\n\n
Note (this is one command line, so copy all and paste in putty and press enter)<\/sub><\/sub><\/p>\n\n\n\n
<\/figure>\n\n\n\nPostal SMTP install command<\/strong><\/h3>\n\n\n\n
In the installation process, you don\u2019t need to do anything because the setup is fully automated. Just wait a couple of minutes for the process to complete. <\/p>\n\n\n\n
Once it is done, you\u2019ll receive the notification \u201cinstallation complete\u201d.<\/p>\n\n\n\n
Now create a user to login and manage your postal server through the web interface. Simply run the following command<\/p>\n\n\n\n
postal make-user<\/code><\/pre>\n\n\n\n
After this, you\u2019re required to enter your name, email, and password. Then press enter after putting the required data in the input.<\/p>\n\n\n\n
Now you\u2019ve installed the postal.<\/p>\n\n\n\n
Configure Postal SMTP<\/strong><\/h3>\n\n\n\n
Configure Postal SMTP<\/p>\n\n\n\n
After the installation, open the internet browser and navigate to your server IP URL or Subdomain like this:<\/p>\n\n\n\n
https://Sg-educate.com<\/code><\/pre>\n\n\n\n
After this, you will get an SSL warning. It\u2019s ok! Just click on \u201cproceed\u201d as you can see in the image given below:<\/p>\n\n\n\n
<\/figure>\n\n\n\nWelcome to Postal<\/strong><\/h3>\n\n\n\n
And then you\u2019ll see the postal login screen where you\u2019ve to enter your email & password that you created during the setup.<\/p>\n\n\n\n
<\/figure>\n\n\n\nPostal Login<\/strong><\/h3>\n\n\n\n
After getting inside the postal click \u201cAdd Organization\u201d to add one. Then you will see the \u201cBuild Server\u201d on the lower-left corner click on it and set it to live mode.<\/p>\n\n\n\n
<\/figure>\n\n\n\nPostal Domain Configuration<\/strong><\/h3>\n\n\n\n
Now you will see the \u201cAdd your first domain\u201d so click on it and add your domain name into postal.<\/p>\n\n\n\n
<\/figure>\n\n\n\nAdd Domain in Postal<\/strong><\/h3>\n\n\n\n
Simply, enter your domain name to send emails and click \u201cCreate Domain\u201d. Then you\u2019ll see the Domain page with the records that you need to fill.<\/p>\n\n\n\n
<\/figure>\n\n\n\nPostal DNS Records<\/strong><\/h3>\n\n\n\n
Simply, copy these records from SPF & DKIM and then paste them in the DNS Zone. Now your server is ready to send emails! <\/p>\n\n\n\n
But what are SPF and DKIM? <\/p>\n\n\n\n
DKIM (Domain Keys Identified Mail):<\/strong><\/h3>\n\n\n\n
As you can see in the above image there is a DKIM record mentioned so whatm. is this? This a text record in your DNS and its function is to hold a public authentication key. Later it will protect your email originality and this is very important for your server. <\/p>\n\n\n\n
Setup DKIM For Postal<\/strong><\/h3>\n\n\n\n
The good thing about Postal is that DKIM is already configured and its keys are also generated. You just have to copy the DKIM record in your DNS Zone. <\/p>\n\n\n\n
<\/figure>\n\n\n\nSPF (Sender Policy Framework):<\/strong><\/h3>\n\n\n\n
An SPF is also a text record added to the DNS zone, and it specifies the mail servers authorized to send an email for your domain. The message or email will be marked as spam if the server isn\u2019t authorized or allowed by the SPF record.<\/p>\n\n\n\n
For example: if you try to send an email from a Google domain like mail@google.com then your email will be marked as spam because you can\u2019t use the google domain. <\/p>\n\n\n\n
You can also configure SPF and prevent from others try to send an email from your domain. So, SPF configuring is very important to make your domain trustable for other mailing service providers.<\/p>\n\n\n\n
Set up SPF<\/strong><\/h3>\n\n\n\n
- Open your DNS zone and add the following record:<\/strong><\/li><\/ul>\n\n\n\n
v=spf1 a mx ip4:XXX.XXX.XXX.XXX -all<\/code><\/pre>\n\n\n\n
- Replace the given IP with your VPS server IP.<\/li><\/ul>\n\n\n\n
Now, only your server is allowed to send an emails from your domain.<\/p>\n\n\n\n
If you noticed, there is an SPF example given by the postal and that looks like:<\/p>\n\n\n\n
v=spf1 a mx include:spf.postal.example.com ~all<\/code><\/pre>\n\n\n\n
You have to change the example domain and configure file in the postal to match your domain.<\/p>\n\n\n\n
How to Edit Postal Configuration File<\/strong><\/h3>\n\n\n\n
First, you\u2019ve to connect the server to edit the postal configuration file, use a file manager to connect with your server. There is a WinSCP a free remote file manager used to connect or edit configuration files. <\/p>\n\n\n\n
It is simple and easy to use:<\/p>\n\n\n\n
- Just go to WinSCP, and use the root credentials to connect with your server.<\/li>
- Then open the \/opt\/postal\/config Directory<\/li><\/ul>\n\n\n\n
<\/figure>\n\n\n\n
- Postal.yml configuration<\/li>
- Then, right-click and edit the file.<\/li><\/ul>\n\n\n\n
<\/figure>\n\n\n\nPostal Domain Change<\/strong><\/h3>\n\n\n\n
After replacing the example domain with your domain name you need to restart postal so that the configuration comes in action.<\/p>\n\n\n\n
So run this command on your server: <\/p>\n\n\n\n
Postal restart<\/code><\/pre>\n\n\n\n
So, when you refresh your web page the example.com will change into your domain name.<\/p>\n\n\n\n
<\/figure>\n\n\n\nNow You Can Send A Test Email<\/strong><\/h3>\n\n\n\n
Now postal is ready to send testing emails so, click on the messages and then click on the send messages to test the free SMTP server.<\/p>\n\n\n\n
<\/figure>\n\n\n\nSend a test message<\/strong><\/h3>\n\n\n\n
If you\u2019ve worries regarding the use of SMTP to send emails then don\u2019t be panic, all you just have to create credentials inside the postal to connect with the free SMTP server. <\/p>\n\n\n\n
Create Postal Credentials to Relay Emails<\/p>\n\n\n\n
Simply, click on Credentials<\/strong>, then Add your first Credentials<\/strong>. <\/p>\n\n\n\n
<\/figure>\n\n\n\nIn type (input): select SMTP. But if you don\u2019t want to connect to connect postal through SMTP then you can also select API to develop your own application.<\/p>\n\n\n\n
- Enter a User <\/strong>name<\/li>
- In key (input): you can keep it as \u201cautomatically generated<\/strong>\u201c<\/li><\/ul>\n\n\n\n
<\/figure>\n\n\n\nAnd the process is done here, now you can use these credentials in any email marketing.<\/p>\n\n\n\n
Relay a Test Email<\/strong><\/h3>\n\n\n\n
Simply, Go to SMTPER.NET and enter your server details as follows:<\/p>\n\n\n\n
<\/figure>\n\n\n\nTest your SMTP here:<\/p>\n\n\n\n
- SMTP Host: Your Server IP or Domain<\/li><\/ul>\n\n\n\n
- Port: 25 or 2525<\/li><\/ul>\n\n\n\n
- Login: The User You entered in credentials.<\/li><\/ul>\n\n\n\n
- Password: The User Password.<\/li><\/ul>\n\n\n\n
You can use these credentials in Email Sender<\/a> application. <\/p>\n\n\n\n
Before Sending An Email<\/strong><\/h3>\n\n\n\n
Before sending an email, you\u2019ve to keep some crucial concepts in your mind. So, follow these guidelines to get the best delivery rates. <\/p>\n\n\n\n
Warming Up your SMTP server<\/strong><\/h2>\n\n\n\n
Before starting your email marketing campaign warm-up your IP Address. Because it\u2019ll build your reputation on the internet and increase your volume of mail sent according to schedule. <\/p>\n\n\n\n
Why it is so important<\/strong><\/h3>\n\n\n\n
It is important because when your IP Address is brand new in the competitive environment, it has no reputation on the internet and no one knows about this IP Address. So, the IP warmup is basically the practice to build a reputation on the internet. <\/p>\n\n\n\n
Example of warming up your server shown in the table below:<\/p>\n\n\n\n
Warmup Day<\/td> Emails To Send<\/td><\/tr> 1<\/td> 20<\/td><\/tr> 2<\/td> 50<\/td><\/tr> 3<\/td> 100<\/td><\/tr> 4<\/td> 300<\/td><\/tr> 5<\/td> 500<\/td><\/tr> 6<\/td> 700<\/td><\/tr> 7<\/td> 900<\/td><\/tr> 8<\/td> 1000<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n This Table shows a scenario, if your target is 1K emails per day with the good reputation.<\/p>\n\n\n\n
RDNS (Reverse DNS):<\/strong><\/h3>\n\n\n\n
The reverse DNS is also known as a pointer record. It is used to point your IP to your Domain and it works contrary to regular DNS. <\/p>\n\n\n\n
RDNS is the essential element in your mail server and increasing your sending score. It will also improve your reputation on the internet. So, when you\u2019ll search the IP you will get the name.<\/p>\n\n\n\n
DMARC (Domain-based Message Authentication, Reporting & Conformance):<\/strong><\/h3>\n\n\n\n
It is basically the protocol used to monitor the authenticity of email messages using SPF & DKIM. DMARC has made it easier for ISPs (internet service providers) to prevent malicious emails. It allows the email senders to handle unauthenticated emails by using SPF or DKIM records. The sender can whether move the unauthenticated emails to the junk folder or can block them all.<\/p>\n\n\n\n
MX Record<\/strong><\/h3>\n\n\n\n
MX (Mail Exchange) records are DNS records responsible for delivering email to your address. In simple words, Max record tells the world about the mail servers which allows incoming traffic to your domain and the route of the sent email. <\/p>\n\n\n\n
Avoid Spam Factors<\/strong><\/h3>\n\n\n\n
Four factors can determine the spam scores, given below:<\/p>\n\n\n\n
- IP Reputation<\/li>
- SPF, DKIM, rDNS, and DMARC.<\/li>
- Message Body<\/li>
- Email List health.<\/li><\/ul>\n\n\n\n
We have already discussed the first two factors above but there is still Message Body and Email List Health. <\/p>\n\n\n\n
Message body<\/strong><\/h3>\n\n\n\n
In this factor, the health of the email matter the most. The subject line and the content of the email should be attractive and professional. If the email looks spammy, then the recipient will not get your email and your email will directly move to the spam folder. So, avoid using spammy words & triggers.<\/p>\n\n\n\n
Email List Health<\/strong><\/h3>\n\n\n\n
The health of the email list is determined by the following two things:<\/p>\n\n\n\n
- Bounce Rate: The number of valid emails in your list<\/li>
- Spam Traps: Are there any spam traps on your list?<\/li><\/ul>\n\n\n\n
Secure with a Free SSL.<\/strong><\/h3>\n\n\n\n
SSL certificates encrypt the traffic between the server and client to provide extra security for users to access your application. It provides an easy way to install trusted certificates for free. Connect it to your server using putty SSH client. Get ready to install!<\/p>\n\n\n\n
Step 1 \u2014 Install Encrypt Client<\/strong><\/h3>\n\n\n\n
Let\u2019s Encrypt client certificate are installed through client software running on your server. <\/p>\n\n\n\n
The official client is called Cerbot which is installed by running this command:<\/p>\n\n\n\n
apt -y install certbot<\/code><\/pre>\n\n\n\n
Step 2 \u2014 Get the SSL Certificate<\/strong><\/h3>\n\n\n\n
The second step is you need to stop Nginx service because it is using port 80 which will be used by Cerbot. So, stop this service temporarily by running the following command:<\/p>\n\n\n\n
sudo systemctl stop nginx<\/code><\/pre>\n\n\n\n
Now install the certificate by running the following command:<\/p>\n\n\n\n
certbot certonly --standalone -d postal.example.com<\/code><\/pre>\n\n\n\n
Replace the following domain with your domain. And then follow the Wizard. The Cerbot will issue you the certificate for your domain.<\/p>\n\n\n\n
Step 3 \u2014 Configure the SSL Certificate<\/strong><\/h3>\n\n\n\n
Now you\u2019ve got the server but you need to configure it in your server. So, start the Nginx service again by running the following command:<\/p>\n\n\n\n
sudo systemctl start nginx<\/code><\/pre>\n\n\n\n
- Open the WinSCP again and edit some files on your server.<\/li>
- Connect to your server and go to \/etc\/Nginx\/conf.d<\/strong> directory.<\/li>
- Create a new file and name in it: \u201cpostal.example.com<\/em><\/strong>.conf<\/strong>\u201c<\/li>
- Then replace \u201cpostal.example.com<\/em><\/strong>.conf<\/strong>\u201c with your domain<\/li>
- And copy the code and paste it inside the file given below:<\/li><\/ul>\n\n\n\n
server {\n listen [::]:80;\n listen 0.0.0.0:80;\n server_name postal.example.com;\n return 301 https:\/\/$host$request_uri;\n}\n\nserver {\n listen [::]:443 ssl;\n listen 0.0.0.0:443 ssl;\n root \/opt\/postal\/public;\n server_name postal.example.com;\n ssl_certificate \/etc\/letsencrypt\/live\/postal.example.com\/fullchain.pem;\n ssl_certificate_key \/etc\/letsencrypt\/live\/postal.example.com\/privkey.pem;\n ssl_protocols TLSv1.2 TLSv1.1 TLSv1;\n ssl_prefer_server_ciphers on;\n ssl_ciphers EECDH+ECDSA+AESGCM:EECDH+aRSA+AESGCM:EECDH+ECDSA+SHA512:EECDH+ECDSA+SHA384:EECDH+ECDSA+SHA256:ECDH+AESGCM:ECDH+AES256:DH+AESGCM:DH+AES256:RSA+AESGCM:!aNULL:!eNULL:!LOW:!RC4:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS;\n\n location \/ {\n client_max_body_size 50M;\n try_files $uri $uri\/index.html $uri.html @puma;\n }\n\n location \/app\/assets {\n add_header Cache-Control max-age=3600;\n }\n\n location @puma {\n proxy_set_header X-Real-IP $remote_addr;\n proxy_set_header Host $host;\n proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\n proxy_set_header X-Forwarded-Proto https;\n proxy_pass http:\/\/127.0.0.1:5000;\n }\n}<\/code><\/pre>\n\n\n\n
- After pasting the code simply, save the file.<\/li>
- The last step is to restart and enable nginx service again by running the following command:<\/li><\/ul>\n\n\n\n
systemctl restart nginx<\/code><\/pre>\n\n\n\n
- Then this command:<\/li><\/ul>\n\n\n\n
systemctl enable nginx<\/code><\/pre>\n\n\n\n
- Now you can test your secure Postal website! Best of luck!<\/li><\/ul>\n\n\n\n
Thanks for reading.<\/span><\/p>\n\n\n\n
If you liked this article and want to read more of these, please subscribe to our newsletter and follow us on Facebook<\/a>, Youtube<\/a>, Linkedin<\/a>, and Twitter<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"