Skip to main content

Command Palette

Search for a command to run...

Host a Static Website in Azure Storage

Published
4 min read

So, you’ve built a sleek little static website, might be a personal portfolio, a landing page for your side project, or a documentation hub for your app. Now comes the million-dollar question: where do you host it without spinning up servers, managing VMs or breaking the bank?

Here’s the secret: Azure Storage can host static websites. Yes!!!, the same place you normally think of for blobs and backups can also serve your HTML, CSS, JavaScript and images directly to the world - no web server required.

The best part? it’s dirt cheap, globally available and just takes a few steps to get running. In less time than it take s to brew your coffee, you can have a live website running on Azure. In this post , I’ll take you through the steps needed to host a static website in Azure storage. Let’s roll!!!……


Step 1: Log in to your Azure portal

Step 2: Search for “Storage Accounts“.

Click on Storage Accounts.

  • After clicking on “storage accounts“, you’ll land on the storage account page.

  • Then click Create.

Step 3: Configure the Basics settings

You’ll now see a Basics tab with these fields:

  • Choose your subscription and Create new Resource group.

  • Name your storage account, make sure the name is unique(you can do well do add numbers).

  • Then pick a region.

  • For the preferred storage type, pick the first.

  • For the Performance, click Standard.

  • For Redundancy, pick Locally-redundant Storage (LRS).

  • Then, click Review + Create.

  • After checking if everything is okay, Click Create.

  • After, Deployment should start (This should take just 2-5 minutes).

Step 4: Host the Website

  • When the deployment is done, Go to resource

  • Then by your left, Click on the Data Management blade.

  • You’ll then see a dropdown, Click on Static website.

  • Click Enabled.

  • Input your index document name and enter an error document path, like given in the image below, then hit save.

  • After this, it will start to update. Wait for it to be successful, when its done you’ll get a primary endpoint

Step 5: Upload your file, image or document

  • Already a container has been created for you. On your left go to Data Storage and click on the Container blade.

  • Click on $web.

  • Make sure you’ve created a file called 404.html, which will be the error document or page.

  • Then click on upload, after click on browse for files.

  • choose the folder you want to upload, you would have to upload one after the other or just copy the files. this because you cannot upload a whole folder.

  • After copying the files, click upload

Step 6: Check your file in the browser

  • When you’re done uploading, go back to the static website blade.

  • Copy the primary endpoint and paste it in your browser


And that’s it! In just a few steps, you’ve gone from a folder full of HTML files on your laptop to a live website hosted on Azure Storage. No servers to babysit, no load balancers to configure, and no late-night patching — just pure static hosting bliss.

The beauty of this setup is its simplicity. It’s cheap, globally available, and scales effortlessly without you lifting a finger. Do you want to get fancy? Throw Azure CDN or Front Door in front of it for global speed boosts and free HTTPS on your custom domain.

whether you’re showing off your portfolio, publishing docs, or launching a side hustle landing page, Azure Storage makes static hosting a no-brainer

Now go ahead — share that link with the world 🌍. Your website is live, and you did it in the time it takes to sip a latte. Pretty awesome, right?

L

Great guide! Hosting static websites on Azure Blob Storage is a cost-effective and scalable solution. For even smoother local development, I’ve started using ServBay (servbay.com) — it lets me spin up isolated environments quickly, so I can test changes without worrying about my main setup.