<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Mehedi Mansur Rafi</title>
    <description>The latest articles on DEV Community by Mehedi Mansur Rafi (@mehedirafi).</description>
    <link>https://dev.to/mehedirafi</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4225276%2F2e9a9458-7202-4b9a-919b-75a5a2d50b09.jpg</url>
      <title>DEV Community: Mehedi Mansur Rafi</title>
      <link>https://dev.to/mehedirafi</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mehedirafi"/>
    <language>en</language>
    <item>
      <title>The cheapest good way to host a small business website</title>
      <dc:creator>Mehedi Mansur Rafi</dc:creator>
      <pubDate>Wed, 04 Nov 2026 05:05:11 +0000</pubDate>
      <link>https://dev.to/mehedirafi/the-cheapest-good-way-to-host-a-small-business-website-53c1</link>
      <guid>https://dev.to/mehedirafi/the-cheapest-good-way-to-host-a-small-business-website-53c1</guid>
      <description>&lt;p&gt;Every small business owner I talk to asks the same question in a different way: "Where should I put my website so it stays online, loads fast, and does not eat money every month?"&lt;/p&gt;

&lt;p&gt;Cheap hosting is easy to find. Cheap hosting that is still good in year two is the real problem. This post walks through the two routes that make sense for a small business site, what each one actually costs you over time, and how to pick.&lt;/p&gt;

&lt;p&gt;A note before the details: some links in my posts may be affiliate links. I only write about services I have checked carefully, and I will say plainly when a recommendation is based on a provider's published terms rather than my own usage.&lt;/p&gt;

&lt;h2&gt;
  
  
  What a small business website actually needs
&lt;/h2&gt;

&lt;p&gt;Strip away the marketing pages and a business site needs five things:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;HTTPS (SSL)&lt;/strong&gt; — free at any decent host now. If a plan charges extra for SSL, walk away.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Backups you can restore&lt;/strong&gt; — not just "backups exist", but a button you can press to roll the site back.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A renewal price you can live with&lt;/strong&gt; — the first-term price is advertising. The renewal price is the real price.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Support that answers&lt;/strong&gt; — when your site is down before a workday, a slow ticket queue costs more than the hosting saved you.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Room for one step of growth&lt;/strong&gt; — a contact form today, a booking page or small shop next year, without migrating on day one.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Keep those five in mind and most "unlimited everything for $1" offers sort themselves out.&lt;/p&gt;

&lt;h2&gt;
  
  
  Route 1: Shared hosting (the budget route)
&lt;/h2&gt;

&lt;p&gt;Shared hosting means your site lives on a server with many other sites, and the provider manages everything: updates, security patches, the control panel. Hostinger is the name that comes up most in this category right now, and its published model is the standard one for budget shared hosting: a low introductory price when you pay for a long first term, then a higher renewal price afterwards.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Who it fits:&lt;/strong&gt; a brochure site, a blog, a portfolio, a small shop that is just starting. WordPress and simple PHP sites run fine here.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What to check before you buy:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The renewal price, not the banner price. Work out the cost over three years, not three months.&lt;/li&gt;
&lt;li&gt;How long the first term must be to get the low price. A 4-year commitment is a real decision, not a discount detail.&lt;/li&gt;
&lt;li&gt;Whether backups are included in the plan tier you picked, or only in the tier above.&lt;/li&gt;
&lt;li&gt;Whether business email is included or sold separately.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;The honest trade-off:&lt;/strong&gt; you give up control and some speed headroom, and in exchange you pay the least and manage almost nothing. For a site whose job is to be found and to look trustworthy, that trade is usually right.&lt;/p&gt;

&lt;h2&gt;
  
  
  Route 2: Managed cloud hosting (the growth route)
&lt;/h2&gt;

&lt;p&gt;A step up is a cloud server (a VPS) with a management layer on top. Cloudways is the example I use when explaining this route: you pick a cloud server from providers like DigitalOcean or Vultr, and their platform handles the server setup, updates, caching, and backups for a monthly fee on top of the server cost.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Who it fits:&lt;/strong&gt; a site that runs custom code (for example a Laravel application), a shop that is starting to sell seriously, or any site where slow loading directly costs orders.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What to check before you buy:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The total monthly number: platform fee plus server size. It is monthly, with no long commitment, which makes the real cost easier to see than an intro offer.&lt;/li&gt;
&lt;li&gt;Email is usually NOT included. Budget for a separate email service if the business needs mailboxes on the domain.&lt;/li&gt;
&lt;li&gt;Backups and staging (a safe copy of the site to test changes on) are the features you are really paying for. If you will never use staging, you may be paying for headroom you do not need yet.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;The honest trade-off:&lt;/strong&gt; it costs several times more than budget shared hosting, and in exchange you get speed, scaling, and tools that matter once the site earns money.&lt;/p&gt;

&lt;h2&gt;
  
  
  The costs people forget
&lt;/h2&gt;

&lt;p&gt;Whichever route you pick, these are the lines that surprise people later:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Renewal jumps.&lt;/strong&gt; A plan that starts at a few dollars a month can renew at two or three times that. Put the renewal date and price in your calendar the day you buy.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Domain privacy and renewals.&lt;/strong&gt; The domain itself renews every year, and privacy protection is worth having.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Your own hours.&lt;/strong&gt; The cheapest plan that takes you a weekend to fix is not cheap. Price your time honestly.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Migration pain.&lt;/strong&gt; Leaving a host is easiest before you need to. Keep your own copy of the site's files and database from day one, outside the host.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  A simple way to decide
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Your site is pages, photos, a contact form, maybe a small shop starting out → &lt;strong&gt;shared hosting&lt;/strong&gt; (route 1). Spend the savings on a good design and your Google Business Profile.&lt;/li&gt;
&lt;li&gt;Your site runs an application, takes bookings or payments you depend on, or you expect real growth this year → &lt;strong&gt;managed cloud&lt;/strong&gt; (route 2). The monthly cost is a business expense, and downtime is the expensive option.&lt;/li&gt;
&lt;li&gt;You are not sure → start on route 1 with a short enough term that changing your mind is painless, and move up when the site gives you a reason. Moving a simple site is a routine job; I wrote up the general shape of putting a site online in my previous post.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  If you would rather hand this over
&lt;/h2&gt;

&lt;p&gt;Choosing the host is the easy part. Setting the site up cleanly, connecting the domain, and keeping it updated is the ongoing work. If you want help with that, I take small website jobs and monthly care work through Upwork and Fiverr — the links are on my profile here. Tell me what the site needs to do, and I will tell you honestly which of the two routes above it belongs on, including when the answer is the cheaper one.&lt;/p&gt;

</description>
      <category>webdevbegintutorialners</category>
    </item>
    <item>
      <title>How to put a Laravel website online, step by step</title>
      <dc:creator>Mehedi Mansur Rafi</dc:creator>
      <pubDate>Wed, 04 Nov 2026 03:39:00 +0000</pubDate>
      <link>https://dev.to/mehedirafi/how-to-put-a-laravel-website-online-step-by-step-3oif</link>
      <guid>https://dev.to/mehedirafi/how-to-put-a-laravel-website-online-step-by-step-3oif</guid>
      <description>&lt;p&gt;&lt;em&gt;Disclosure: some links in this post may be affiliate links. If you buy hosting&lt;br&gt;
through one of them, I earn a commission and you pay the same price. I only&lt;br&gt;
link to services I would use for my own projects.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;A Laravel app that runs on your laptop is not finished. It is finished when a&lt;br&gt;
stranger can open it in a browser. This is the full path I use when I deploy&lt;br&gt;
Laravel projects for myself and for clients, written in the order I actually&lt;br&gt;
do the work.&lt;/p&gt;
&lt;h2&gt;
  
  
  What you need before you start
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;A domain name. Any registrar works.&lt;/li&gt;
&lt;li&gt;A server or hosting account that runs PHP 8.2 or newer and MySQL.&lt;/li&gt;
&lt;li&gt;Your Laravel project in a Git repository, or as a clean zip without
&lt;code&gt;vendor/&lt;/code&gt; and &lt;code&gt;node_modules/&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For a small Laravel site you have two sane choices. Shared hosting is cheap&lt;br&gt;
and fine for low traffic, but you get no SSH on most plans, and that makes&lt;br&gt;
Laravel painful. A managed cloud server costs a bit more and removes most of&lt;br&gt;
that pain. This walkthrough uses Cloudways, because it gives you a real&lt;br&gt;
server with SSH, Git deployment and SSL handled, without making you&lt;br&gt;
administer the machine itself. Their plans are listed at&lt;br&gt;
&lt;a href="https://www.cloudways.com" rel="noopener noreferrer"&gt;https://www.cloudways.com&lt;/a&gt; (plain link).&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 1: Create the server and the application
&lt;/h2&gt;

&lt;p&gt;In Cloudways, launch a server (DigitalOcean or Vultr, 1–2 GB RAM is enough&lt;br&gt;
for a small app), then add an application and choose "Custom PHP App" or the&lt;br&gt;
Laravel option if it is offered. Cloudways creates the database, the SFTP&lt;br&gt;
user and the folder structure for you. Write down three things: the server&lt;br&gt;
IP, the application public path (it ends in &lt;code&gt;public_html&lt;/code&gt;), and the database&lt;br&gt;
name, user and password from the application's Access Details page.&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 2: Get your code onto the server
&lt;/h2&gt;

&lt;p&gt;Two ways work well:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Git:&lt;/strong&gt; add the server as a deployment target and pull your repository
into the application folder. Best if you deploy often.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Upload:&lt;/strong&gt; zip your project locally (without &lt;code&gt;vendor/&lt;/code&gt;), upload it through
SFTP or the file manager, extract it into the application folder, then run
&lt;code&gt;composer install&lt;/code&gt; over SSH.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;After the code is there, run these once:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;composer &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;--no-dev&lt;/span&gt; &lt;span class="nt"&gt;--optimize-autoloader&lt;/span&gt;
&lt;span class="nb"&gt;cp&lt;/span&gt; .env.example .env
php artisan key:generate
php artisan storage:link
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Step 3: Point the web root at the &lt;code&gt;public&lt;/code&gt; folder
&lt;/h2&gt;

&lt;p&gt;This is the step people skip, and then every route returns 404. Laravel's&lt;br&gt;
entry point is &lt;code&gt;public/index.php&lt;/code&gt;. The web server must serve the &lt;code&gt;public&lt;/code&gt;&lt;br&gt;
folder, not the project root. On Cloudways the application already serves&lt;br&gt;
from &lt;code&gt;public_html&lt;/code&gt;, so make sure your project root sits in &lt;code&gt;public_html&lt;/code&gt; and&lt;br&gt;
that &lt;code&gt;public_html/public&lt;/code&gt; is not an extra nested level. On shared hosting,&lt;br&gt;
create the subdomain or addon domain with its document root ending in&lt;br&gt;
&lt;code&gt;/public&lt;/code&gt;. If you get this wrong, no &lt;code&gt;.htaccess&lt;/code&gt; trick will save you.&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 4: Fill in &lt;code&gt;.env&lt;/code&gt; for production
&lt;/h2&gt;

&lt;p&gt;Open &lt;code&gt;.env&lt;/code&gt; on the server and set the values that matter:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight conf"&gt;&lt;code&gt;&lt;span class="n"&gt;APP_ENV&lt;/span&gt;=&lt;span class="n"&gt;production&lt;/span&gt;
&lt;span class="n"&gt;APP_DEBUG&lt;/span&gt;=&lt;span class="n"&gt;false&lt;/span&gt;
&lt;span class="n"&gt;APP_URL&lt;/span&gt;=&lt;span class="n"&gt;https&lt;/span&gt;://&lt;span class="n"&gt;yourdomain&lt;/span&gt;.&lt;span class="n"&gt;com&lt;/span&gt;
&lt;span class="n"&gt;DB_DATABASE&lt;/span&gt;=&lt;span class="n"&gt;your_database_name&lt;/span&gt;
&lt;span class="n"&gt;DB_USERNAME&lt;/span&gt;=&lt;span class="n"&gt;your_database_user&lt;/span&gt;
&lt;span class="n"&gt;DB_PASSWORD&lt;/span&gt;=&lt;span class="n"&gt;your_database_password&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;APP_DEBUG=false&lt;/code&gt; is not decoration. With debug on, an error page shows your&lt;br&gt;
file paths, your environment values and parts of your code to anyone who&lt;br&gt;
triggers an error. Turn it off before the site is public, every time.&lt;/p&gt;

&lt;p&gt;Then:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;php artisan config:cache
php artisan route:cache
php artisan view:cache
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Step 5: Create the database tables
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;php artisan migrate &lt;span class="nt"&gt;--force&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;--force&lt;/code&gt; is required in production; without it Artisan asks for confirmation&lt;br&gt;
and your deployment script hangs. If your host gives you no SSH and no&lt;br&gt;
Artisan, export the SQL from your local database and import it through&lt;br&gt;
phpMyAdmin instead. It is slower and easier to get wrong, which is one more&lt;br&gt;
reason to pick hosting with SSH.&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 6: Fix file permissions
&lt;/h2&gt;

&lt;p&gt;Uploads made through a file manager often land with permissions the web&lt;br&gt;
server cannot read. The symptom is a white page or a 500 error right after a&lt;br&gt;
"successful" upload. The fix:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Files: &lt;code&gt;644&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Folders: &lt;code&gt;755&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;storage/&lt;/code&gt; and &lt;code&gt;bootstrap/cache/&lt;/code&gt; must be writable by the web server.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;chmod&lt;/span&gt; &lt;span class="nt"&gt;-R&lt;/span&gt; 755 storage bootstrap/cache
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;h2&gt;
  
  
  Step 7: Connect the domain and turn on SSL
&lt;/h2&gt;

&lt;p&gt;Point your domain's A record to the server IP. In Cloudways, add the domain&lt;br&gt;
under Domain Management for the application, then issue the free Let's&lt;br&gt;
Encrypt certificate from the SSL page. Wait for DNS to spread (a few minutes&lt;br&gt;
to a few hours), then open the site with &lt;code&gt;https://&lt;/code&gt; and check that the padlock&lt;br&gt;
shows and no page element still loads over plain &lt;code&gt;http://&lt;/code&gt;.&lt;/p&gt;
&lt;h2&gt;
  
  
  Step 8: Add the scheduler and queues
&lt;/h2&gt;

&lt;p&gt;Laravel's scheduler needs one cron line on the server:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="nb"&gt;cd&lt;/span&gt; /path-to-your-app &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; php artisan schedule:run &lt;span class="o"&gt;&amp;gt;&amp;gt;&lt;/span&gt; /dev/null 2&amp;gt;&amp;amp;1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Cloudways lets you add this from the application's Cron Job Management page.&lt;br&gt;
If your app sends mail or does slow work in queues, run a queue worker under&lt;br&gt;
a supervisor (Cloudways has one built in) instead of letting requests wait:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;php artisan queue:work &lt;span class="nt"&gt;--tries&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;3
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Step 9: Test like a visitor, not like the developer
&lt;/h2&gt;

&lt;p&gt;Open the site in a private browser window. Register an account. Log out and&lt;br&gt;
back in. Submit every form. Upload a file if your app takes uploads. Then&lt;br&gt;
check on your phone. I test this way because the developer session hides&lt;br&gt;
bugs: you are logged in as admin, your browser has cached assets, and your&lt;br&gt;
&lt;code&gt;.env&lt;/code&gt; mistakes only show for guests. Half the deployment bugs I have fixed&lt;br&gt;
for clients were invisible from the developer's own chair.&lt;/p&gt;

&lt;h2&gt;
  
  
  The short checklist
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Code on the server, &lt;code&gt;composer install --no-dev&lt;/code&gt; done.&lt;/li&gt;
&lt;li&gt;Web root points at &lt;code&gt;public&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;.env&lt;/code&gt; set, &lt;code&gt;APP_DEBUG=false&lt;/code&gt;, key generated.&lt;/li&gt;
&lt;li&gt;Database migrated.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;storage/&lt;/code&gt; writable, permissions sane.&lt;/li&gt;
&lt;li&gt;Domain connected, SSL on.&lt;/li&gt;
&lt;li&gt;Scheduler cron added.&lt;/li&gt;
&lt;li&gt;Tested logged-out, on desktop and on a phone.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Do those eight and your Laravel site is online in a way that stays online.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;I deploy and maintain Laravel websites for small businesses. If your site is&lt;br&gt;
stuck on one of these steps, or you want someone to look after updates,&lt;br&gt;
backups and fixes every month, you can hire me on&lt;br&gt;
&lt;a href="https://www.upwork.com/freelancers/~0118ab607e0b4c599b" rel="noopener noreferrer"&gt;Upwork&lt;/a&gt; or&lt;br&gt;
&lt;a href="https://www.fiverr.com/mehedi__rafi" rel="noopener noreferrer"&gt;Fiverr&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>laravelphpwetutorialbdev</category>
    </item>
  </channel>
</rss>
