We’ve all seen the TV adverts offering pre-built websites and packages. But what if you’re a small business and just want something super-simple? Believe it or not, there’s a way you could run a static website for less than a latte [a year not a month]
Yes, you read that right. If all you need is a way to show a couple of static web pages you could run a static website for less than the cost of a coffee for the entire year. Although the focus here is a small, simple, and static website, you can apply the same logic to larger sites or even if you need a way to serve up static content over HTTP, not just a website.
What do we mean by a static website?
In web terms, there are primarily two types of website: those which are static based on traditional Hypertext Markup Language (HTML) files and those which are dynamic, calculating different content server-side or retrieving information from a database.
Here, we’re talking about the former. Using the Static Website feature in Azure Storage, we can serve up HTML, JavsScript, and Cascading Stylesheets (CSS).
How does it work?
To do this, we serve up the HMTL, JS, and CSS files from an Azure Storage Account without any extra components like a web application, a server, a database, nothing.
Once we enable the Static Website feature on the Azure Storage Account, we can point the Domain Name Service (DNS) records for your own domain name to it and away you go.
How would I upload and update the files?
There are many ways to connect to Azure Storage Accounts. One of the easiest is to use the Azure Storage Extension for Visual Studio Code allowing you to access, edit, and upload files all in one place. Alternatively, you can use the Azure Storage Explorer application, or command-line connections like PowerShell.
Unlike an Azure Web App which we would use to run a fully-fledged website, we don’t have the option of connecting via FTP or integrating other platforms such as Azure DevOps or Git into this process for Continuous Delivery.
How do I run a static website in Azure?
Customers can create their own Azure Subscription to create the resources in. All that’s needed is a single Resource Group and a single Storage Account. Storage Accounts can be created using different levels of availability such as Locally Redundant, Zone Redundant, or even Geo-Redundant.
If you want to try it yourself, you can head to https://docs.microsoft.com/en-us/azure/storage/blobs/storage-blob-static-website for all the information.
If all you are hosting in Microsoft Azure were the Storage Account as described, the cost to run a static website is going to be a few pence per month in most cases. Azure Storage does bill for storage transactions so if your website started to receive a lot of visitors then this may start to increase, however, you can set-up Cost Management within Azure to monitor and manage this spend.
Whether you’re looking to host a small static website or whether you need a globally scaled, enterprise platform for your web application, Microsoft Azure can scale to achieve it and Arcible can help you design and build it. Get in touch with us to find out more.