Hey %username%!
Today, many novice web developers make a big mistake, and more than one. They make up something, and then they buy hosting. Next, buy a domain. Register and connect an SSL certificate. I, escaping from negative karma, will simply tell you how don't waste money for your test projects.
By the way, there are absolutely no ads here, even if it seems so to you - this is just another tutorial, with a description of the necessary resources and maximally clear.
I recommend creating a new mail for each such project and registering everywhere using it, and not your personal email.
Hosting
When requesting “
So, today they offer:
- 1 free site
- 1 MySQL database
- PHP Multiple Versions
- Domain connection
- 300mb SSD space (was a gigabyte, miser!)
- FTP
It used to be better, but I think this one is also suitable for our test projects. Moreover, these disadvantages are compensated by a convenient control panel, which not many of its competitors can boast of.
What to do?
- Signing up - it's easy!
- Click "Create a site", do what they ask.
That's all. We will return to 000webhost later. For now…
Domain name
There is no ideal option for work projects. But we're going to do mini-projects and we don't need much - just any second-level domain. Help us -
Here we are approaching the problem
So, we choose.
Action sequence #1
- Signing up - it's easy!
- We go to the "Services" tab from the top, and then - "Register a new domain".
- After that, the service itself will tell you everything.
- After successfully registering the domain, click "Services" again, and there - "My domains". Do not close this tab.
Back to our free hosting…
Action sequence #2
- We go to 000webhost again and see our site with an ugly third-level domain name (sitename.000webhost.com). Let's fix this.
- We move the cursor over a beautiful picture - appeared. the inscription '"Manage the site", click.
- In the left sidebar we see "Tools", follow the link.
- Intuitively select the item "Specify a web address"
- There is a button - "+ Add domain", click!
- A beautiful modal window appears, where we select the first item - we will “park” our domain.
- Enter "Domain name", click on the "magic button" [leave this tab in the background] and go to the tab where you left Freenom.
Action sequence #3
- Here, in the table, opposite the domain, click on the "Manage domain" button.
- When you click on the "Management Tools" tab, a select box will appear where you need to select Nameservers.
- Switch "Use default nameservers (Freenom Nameservers)" to "Use custom nameservers (enter below)"
- Enter “ns01.000webhost.com” at the bottom, and “ns02.000webhost.com” in the next line, and then “Change nameservers”
- We return to the “Webhost” and opposite our “pending” domain, select in the “Manage” select “Check name servers”
- We see that our domain has become active, click "Manage" again and bind it to our sitename.000webhost.com
Yes, now we have everything ready, but we have not solved the last problem that needs to be solved for free - SSL certificate.
Cloudflare
«
Easily
- Sign up for CloudFlare by choosing a free plan.
- Adding our site: you need to go again and change the nameservers in Freenom - remove the old ones and install the ones that the service offers.
- You will immediately be prompted to configure SSL, I recommend the “Flexible” item.
- There are a lot of interesting things in the settings.
Instead of a conclusion
So, your site is set up and is no worse than if you paid money for it. But I recommend adding
<head>
your site, to all pages, like this:
<style>img[alt="www.000webhost.com"] {display: none;}</style>
This way you will hide the annoying 000webhost logo. Many engines, for example
With some skill, it is possible to do all these steps in ~45 minutes. Thus was born
I do not hope that this article has benefited you momentarily, but you can always bookmark it on Habré 🙂 Thanks for reading!
Source: habr.com