Web application architecture: hosting, database, login and CDN
Most web applications follow one proven shape: users reach your app through a CDN, the app runs on a managed platform, and the data lives in a managed database. Here is how the pieces fit, which service plays each part on AWS, Azure and Google Cloud, and what to decide first.
Quick answer
A web application architecture puts a CDN in front of an app that runs on a managed hosting platform, with a managed relational database for data, object storage for uploaded files and a sign-in service for users. DNS, HTTPS certificates, secrets and monitoring surround it. Each cloud has a managed service for every part.
| Best for | Business sites, portals, SaaS products and internal tools with a database and user accounts |
|---|---|
| Less suited when | A site whose pages never change per visitor, where plain static hosting does the job |
| Start with | One managed hosting service and one managed database in one region, with HTTPS from day one |
| Main services on AWS | Amazon Route 53, Amazon S3, Amazon Cognito, Amazon CloudFront, AWS Elastic Beanstalk, Amazon RDS |
| Main services on Azure | Azure DNS, Azure Blob Storage, Microsoft Entra External ID, Azure Front Door, Azure App Service, Azure SQL Database |
| Main services on Google Cloud | Cloud DNS, Cloud Storage, Identity Platform, Cloud CDN, Cloud Run, Cloud SQL |
The idea in plain words
A web application is code that runs on a server, reads and writes a database, and sends pages or data to browsers. In the cloud you rarely manage the servers yourself: a managed platform runs your code, and a managed database handles backups and patching.
Around that core sit a few services that nearly every app needs: a CDN to deliver files quickly, object storage for uploads, a sign-in service so you do not build passwords yourself, DNS and HTTPS certificates for your address, secrets storage for keys, and monitoring.
Start simple: one app service, one database and one region. Add caching, queues and more regions only when measurements show you need them.
The architecture
Boxes show the job each part does. Pick a cloud to see the service for each job.
Step by step
- A user opens your addressThe browser looks up your domain name in DNS and connects over HTTPS, using a certificate that proves the site is yours.
- The CDN answers what it canA CDN serves images, scripts and other files from a location near the user and passes the rest to your app.
- The app platform runs your codeA managed hosting platform runs your application, adds copies when traffic grows and replaces unhealthy ones.
- Check who is signed inA sign-in service handles registration, passwords, multi-factor sign-in and social login, and tells your app who the user is.
- Read and write dataYour code reads and writes a managed relational database, which takes backups and applies patches for you.
- Store files separatelyUploads such as photos and documents go to object storage, not the database, and the browser gets short-lived links when needed.
- Watch it runMonitoring collects errors, speed and cost, and alerts you before users notice a problem. Keys and passwords stay in a secrets service, not in code.
Services side by side
The main service for each job on each cloud, with a second option where one exists. Names checked on 23 October 2026.
| Job | AWS | Azure | Google Cloud |
|---|---|---|---|
| DNS and domain names |
|
|
|
| Object storage (files, images, backups) |
|
|
|
| Customer sign-up and login |
|
|
|
| CDN (fast delivery to users worldwide) |
|
|
|
| Web app or API hosting (managed platform) |
|
|
|
| Relational (SQL) database |
|
|
|
| Monitoring, metrics and alertsOptional |
|
|
|
| HTTPS and TLS certificatesOptional |
|
|
|
| Store secrets (passwords, API keys)Optional |
|
|
|
| Send email (transactional or bulk)Optional |
|
|
|
Common variations
- Traffic is mostly files, such as images and downloads. Serve them through the CDN from object storage, so your app only handles real requests.
- Pages must stay fast for users in many countries. Add copies of the app in more regions behind a global entry point, and decide where the database lives.
- Slow tasks such as reports or emails. Move them to a queue and background workers, so the page responds at once.
- A very small site or a prototype. A static site with a few functions may be enough. See the static website pattern.
Managed platform or your own virtual servers?
A managed hosting platform runs and patches the servers for you. The alternative is to rent virtual servers and run the web server and updates yourself, shown in the table.
| AWS | Azure | Google Cloud | |
|---|---|---|---|
| Virtual servers (VMs) |
|
|
|
Managed hosting platform
Good
- No servers to patch
- Scales and heals automatically
- Quick to deploy
Watch out
- Less control of the operating system
- Platform limits on runtimes and settings
- Cost can rise with scale
Your own virtual servers
Good
- Full control of software and settings
- Runs almost anything, including older software
- Predictable cost for steady load
Watch out
- You patch, secure and scale the servers
- More to monitor and automate
- More effort before the first release
Keep in mind
- Start in one region. Pick a region close to your users and keep data there unless your rules say otherwise. In India, check which regions each cloud offers for the services you need.
- Backups and recovery. Turn on automatic backups and test a restore. Decide how much data loss and downtime you can accept, because it shapes the design.
- Security basics. Use HTTPS everywhere, keep the database off the public internet, give each part only the access it needs, and keep keys in a secrets service.
- Sign-in. Do not build your own password system. Use a sign-in service with multi-factor sign-in, and plan for password resets and account recovery.
- Cost. The usual costs are the app platform, the size of the database and data sent to users. Set a budget alert, start small and review after a month of real traffic.
- Personal data. Accounts mean personal data, which privacy laws such as the GDPR, the CCPA and India's DPDP Act regulate. Collect only what you need, protect it and be able to delete it on request.
- Changes without downtime. Use a pipeline that tests and releases small changes, with a quick way to roll back.
Words used on this page
Services in this pattern that have changed
Cloud providers rename and retire services often. These affect the parts above. Checked on 23 October 2026.
- AWS Closed to new customers AWS App Runner stopped accepting new customers on 30 April 2026. AWS recommends Amazon ECS Express Mode for new container web apps. Details
- AWS Retiring Amazon Pinpoint ends support on 30 October 2026. SMS, voice and push continue as AWS End User Messaging; for email AWS recommends Amazon SES. Details
- Azure Closed to new customers Azure AD B2C has not been sold to new customers since 1 May 2025. Microsoft Entra External ID is the replacement for new projects. Details
Sources and further reading
Check details such as features, limits, prices and regions in the providers' own documentation.
- AWS documentation (opens in a new tab)
- Microsoft Azure documentation (opens in a new tab)
- Google Cloud documentation (opens in a new tab)
Announcements about the changed services above
Frequently asked questions
What is a three-tier web application?
It splits an app into a presentation tier (what users see), an application tier (your code) and a data tier (the database). Cloud web apps follow this shape, usually with a CDN in front and a managed service for each tier.
Which database should I choose for a web app?
Start with a managed relational (SQL) database unless your data is clearly documents or key-value pairs. It is familiar, supports transactions and suits most business apps.
Do I need a CDN?
A CDN helps when users are spread out or you serve many files, because it delivers them from nearby and takes load off your app. A small site with few visitors can add one later.
Can I host a web app for free?
Each cloud has free tiers or credits that can run a small app for a while, but limits and end dates apply. Compare them on CloudBrum's free tier comparison page and set budget alerts.
How do I make a web app highly available?
Run at least two copies of the app in separate zones, use a database with a standby copy in another zone, and put a load balancer or CDN in front. Test a failure on purpose.
Want this reviewed for your case?
CloudBrum architects can adapt this pattern to your documents, users, rules and budget, and estimate the cost. Nothing is sent until you choose.
Building something else?
Describe it in plain words and get matching services on all three clouds.
Service suggester → Cloud consulting →