Here is an idea on how to host a blog or any other static website for very cheap on Azure Blob Storage.
The price will vary with traffic and storage of course… At the moment its € 0.0208 for one GB/Month for storage and € 0.0063 for 10.000 read operations. So you can’t get much cheaper than this (excluding free webspace that always has a catch like ads or expiry dates).
You will need an Azure account for this (click)
Create static files
You could create the static HTML pages manually… But if you prefer to write in Markdown or other easier formats, you should use a tool for static website creation like these: HUGO, MkDocs, Jekyll, NEXT.JS
I created this very blog with HUGO by the way.
Push static files to Azure
After you created the static files, you need to…
- create an Azure Blob Storage
- create a container called $web
- upload your static file to $web
You can use the tool absu to do these steps automatically. Its also great for updating!
Tip: Make sure to keep an offline version of these files. I personally use a private repository on GitHub.
Setup Azure Blob Storage
- enable static website (“Static website” in the storage settings page)
- set index document name (usually your index.html)
- set error document path (the file that is displayed on a 404 errors, 404.html on HUGO)
After that, your website will be accessable on the web endpoint of your Azure Blob Storage. (‘https://*.*.web.core.windows.net/’)
Setup custom domain
If you want to use a custom domain, you need to connect it to an Azure CDN (“Security + network” –> “Azure CDN”) and then create an endpoint within it. In order to do this, you will need to setup a CNAME entry in your Domain name registrar that points to your Azure CDN endpoint (the url will look like: ‘https://*.azureedge.net’).
Sometimes the domain registration process take a few minutes (or even hours). Then finally you can enable “Custom domain HTTPS” in your CDN endpoint so that Azure validates your domain and gives you a valid SSL certificate. This domain validation process can also take just as long.
Once that is done you should be able to connect to your new website with your custom domain!
Could I help? Buy me a drink ! 💙