- Azure
- App Service
- Beginner friendly
- 18 min read
To create an Azure Web App, you fill in one form with eight choices. They are subscription, resource group, name, publish type, runtime, operating system, region and pricing plan. This guide explains what each choice means in plain words, walks through the Azure portal, repeats the same setup with Azure CLI on the Free tier, deploys a small app, and shows how to delete everything so nothing keeps billing you.
Last updated: December 2026
In short
- A web app needs three things around it: a subscription that pays, a resource group that holds it, and an App Service plan that runs it.
- Pick .NET 10 (LTS), not .NET 9. .NET 8 and 9 went out of support in November 2026, and App Service no longer lists them.
- The Free F1 plan costs nothing and is enough to learn. Paid plans bill by the hour even when the app is stopped, so delete the resource group when you finish.

Quick Reference Table
Every part you will meet in this guide, on one screen. Come back to it when a word on the form is unclear.
| Part | What it is | Example in this guide | Why it matters |
|---|---|---|---|
| Azure portal | The website where you manage Azure | portal.azure.com | Where you click through the form |
| Create a resource | The start button for any new service | Create a resource, then Web App | Opens the Web App form |
| Web App | A site, API or backend on Azure App Service | mywebapp-12345 | The thing you are building |
| Subscription | The billing account | Azure subscription 1 | Decides who pays |
| Resource group | A folder for one project’s resources | rg-webapp-demo | Delete it and everything inside goes |
| Name | Becomes part of the web address | mywebapp-12345.azurewebsites.net | Must be unique across Azure |
| Unique default hostname | Adds a random part and the region to the address | …-a1b2c3d4e5f6g7h8.canadacentral-01… | On by default in the portal; stops name clashes |
| Publish | How you deliver the app | Code | Code uses Azure’s runtime; Container uses your image |
| Runtime stack | Language and version | .NET 10 (LTS) | Must be in support and match your app |
| Operating system | Windows or Linux | Linux | Some runtimes exist on only one |
| Region | The Azure location that runs the app | Canada Central | Near your users; cannot change later |
| App Service plan | The machine you rent and its price | Free F1 | Sets the cost, power and features |
What Is an Azure Web App?
A Web App is a website, API or mobile backend hosted on Azure App Service. You bring the code. Microsoft looks after the servers, the operating system updates, the web server and the HTTPS certificate for the default address. You never log in to a machine to patch it.
Four terms come up on every screen, so learn them first:
Subscription
The billing account. Everything you create is charged to one subscription, and a resource belongs to exactly one.
Resource group
A folder for the resources of one project. It costs nothing by itself. Delete the group and everything inside goes with it.
App Service plan
The computer you rent: its region, operating system and pricing tier. One plan can run several web apps, and you pay for the plan, not per app.
Web app
Your site itself: a name, a runtime such as .NET or Python, and your code. It runs on a plan and gets a public address.
Architecture Visualization: What Happens When Someone Opens Your Site
The picture above shows where a web app sits. This one shows what it does. When a visitor types the address, DNS points the browser to Azure. An Azure load balancer receives the request and handles HTTPS there, then passes the request to the machine your plan rents. The runtime (.NET in this guide) hands it to your code, and the answer travels back the same way.

Two things follow from this. Because HTTPS ends at the load balancer, your code receives plain HTTP and does not need a certificate of its own. And on Free F1 the machine is shared with other customers’ apps, which is fine for learning but not for a busy site. Basic and higher run your apps on machines of your own.
Before You Start
- An Azure account. A new Azure free account comes with a $200 credit for the first 30 days, and some services stay free after that.
- A browser for the portal part. Nothing to install.
- Azure CLI for the command line part (optional). Install it from Microsoft’s install page, or use Cloud Shell inside the portal.
What this costs
Nothing, if you choose the Free F1 plan as shown here (the same idea as the AWS Free Tier). Be careful with the paid tiers: a Basic plan is charged for every hour it exists, even when the web app is stopped and even when the plan is empty. Stopping an app does not stop the bill. Deleting the plan does.
Flowchart: The Whole Process at a Glance
This is the full path from opening the portal to deleting your test, with the four places beginners usually get stuck. Each orange diamond is a question. If the answer is yes, do what the box beside it says, then carry on down.

Create an Azure Web App in the Portal: The 8 Choices
Sign in at portal.azure.com, select Create a resource, then Web App, then Create. Your portal may look a little different from screenshots you have seen, because the theme and menu are personal settings. If you get lost, type “App Services” in the search bar at the top. Everything below is on the first tab, Basics.
01 Subscription: Who Pays
Most beginners have only one, so it is already selected. If you have several (for example work and personal), check this field first. A web app created in the wrong subscription is billed to the wrong account.
02 Resource Group: The Project Folder
Select Create new and give it a clear name such as rg-webapp-demo. Use one group per project. When the project ends, you delete one group instead of hunting for leftovers.
03 Name: It Becomes the Web Address
The name is 2 to 60 characters: letters, numbers and hyphens, with no hyphen at the start or end. It becomes part of the public address, so it has to be unique.
In the portal, unique default hostname is switched on by default. Azure then adds a random part and the region to your name, and shows the result under the box:
| Kind of address | Example | When you get it |
|---|---|---|
| Classic default | mywebapp.azurewebsites.net | Unique hostname switched off. The name must be free across all of Azure. |
| Unique default | mywebapp-a1b2c3d4e5f6g7h8.canadacentral-01.azurewebsites.net | The portal default. Safer, because nobody can claim the same address after you delete the app. |
| Custom domain | www.example.com | Added later. Needs a paid tier (not Free F1). |
The long address is fine for learning. A real site hides it behind a custom domain.
04 Publish: Code or Container
Choose Code. Azure supplies the runtime and you upload only your application. Container is for when you have built a Docker image, usually because you need software that the built-in runtimes do not include.
05 Runtime Stack: Language and Version
Pick the language your app is written in. For a .NET app choose .NET 10 (LTS). Many older tutorials say .NET 8 or .NET 9; both went out of support on 10 November 2026 and are gone from the list. .NET 11 is also offered, but it is a short-support release, so LTS is the calmer choice for a first app.
06 Operating System: Windows or Linux
Some runtimes exist on only one of them. This is what the built-in list looked like when we checked it with Azure CLI in December 2026:
| Runtime | Windows | Linux |
|---|---|---|
| .NET 10 and 11 | Yes | Yes |
| ASP.NET (.NET Framework 4.8) | Yes | No |
| Node.js | Yes | Yes |
| Java and Tomcat | Yes | Yes |
| Python | No | Yes |
| PHP | No | Yes |
For modern .NET either one works. Choose Linux unless you need something that is Windows only, such as an old ASP.NET site.
07 Region: Where It Runs
Pick the region closest to the people who will use the site, for example Canada Central. If Azure refuses your first choice (see the quota tip in the CLI part), pick the next closest one. Choose with care: an App Service app cannot be moved to another region later. You would have to create a new one and copy the site across.
08 Pricing Plan: Cost and Power
The portal creates a new App Service plan for you and may preselect a paid tier. Open the pricing plan list and choose Free F1. This is the choice that matters most for your bill.
| Free F1 limit | Value |
|---|---|
| Price | No charge |
| CPU time | 60 minutes per day |
| Memory | 1 GB for the whole plan |
| Storage | 1 GB |
| Custom domain | No, only the azurewebsites.net address |
| Always On | No, the app sleeps when idle and wakes on the next visit |
Move to Basic or higher when you need your own domain, a free managed certificate for it, or an app that never sleeps.
Review, Create and Open the Site
Select Review + create. Azure checks the form. Read the summary once more, mainly the subscription and the pricing plan.
Select Create and wait for “Your deployment is complete”. It takes a short while.
Select Go to resource. On the Overview page, select the web address shown as the default domain.
You should see Microsoft’s placeholder page, which says the web app is running and waiting for your content. The web app works; it only has no code yet.
CLI Equivalent: Create the Same Azure Web App With Azure CLI
Each portal choice has a matching option in Azure CLI. Same concept, typed instead of clicked:
| Portal choice | Azure CLI option | On which command |
|---|---|---|
| 01 Subscription | --subscription "<name or ID>" | az account set |
| 02 Resource group | --name rg-webapp-demo | az group create |
| 03 Name | --name mywebapp-12345 | az webapp create |
| 03 Unique default hostname | --domain-name-scope TenantReuse | az webapp create |
| 04 Publish: Code | --runtime (Container uses --container-image-name) | az webapp create |
| 05 Runtime stack | --runtime "DOTNETCORE:10.0" | az webapp create |
| 06 Operating system | --is-linux (or --is-linux false) | az appservice plan create |
| 07 Region | --location canadacentral | az group create (the plan uses the group’s region unless you add its own) |
| 08 Pricing plan | --sku F1 | az appservice plan create |
The portal is good for learning what the choices mean. The command line is better once you repeat the job, because the same commands always give the same result. (When you want the whole setup written down as code, Terraform is the step after that.) Run them one at a time. Replace mywebapp-12345 with your own unique name.
Sign in:
az loginCreate the resource group in Canada Central:
az group create --name rg-webapp-demo --location canadacentralCreate a Free Linux plan:
az appservice plan create --name plan-webapp-demo --resource-group rg-webapp-demo --sku F1 --is-linuxAlways write the SKU and the operating system
Older notes say this command makes a Basic Windows plan when you leave the options out. That is no longer true. Current Azure CLI creates a Linux plan unless you add --is-linux false, and without --sku you can end up on a paid tier. Type both every time.
Create the web app with .NET 10 on that plan:
az webapp create --name mywebapp-12345 --resource-group rg-webapp-demo --plan plan-webapp-demo --runtime "DOTNETCORE:10.0"If the plan fails with a quota error
In our test, the Free plan was refused in Canada Central with “Operation cannot be completed without additional quota … Current Limit (F1 App Service instances): 0”. Some subscriptions have no Free quota in some regions. The quick fix is another region: add --location centralindia (or any region that works for you) to the plan command. The slower fix is a quota request on the portal’s Quotas page.
The runtime text is different per operating system: DOTNETCORE:10.0 on Linux and dotnet:10 on Windows. To see every valid value, list them:
az webapp list-runtimes --os-type linuxPrint the address of your new site:
az webapp show --name mywebapp-12345 --resource-group rg-webapp-demo --query defaultHostName --output tsvIn our test this printed <name>.azurewebsites.net, and that address showed Microsoft’s welcome page straight away. Unlike the portal, the CLI gives you the classic short address unless you ask for a unique one with --domain-name-scope TenantReuse when you create the app. You may also see az webapp up in older guides. It is deprecated, so use the commands above.
A Tiny .NET App to Put on It
This is the whole program. We built and ran it on a PC with the .NET 10 SDK, and both addresses answered:
var builder = WebApplication.CreateBuilder(args);
var app = builder.Build();
app.MapGet("/", () => "Hello from Azure Web App");
app.MapGet("/health", () => Results.Ok("Healthy"));
app.Run();Create the project it belongs in, then replace the generated Program.cs with the code above:
dotnet new web -n HelloAzureRun it on your own PC first, from inside the HelloAzure folder:
dotnet runOpen the address it prints. / shows the greeting and /health shows "Healthy". The second address is a health check: a simple page that monitoring tools can call to ask whether the app is alive.
Code Breakdown: The Sample App, Line by Line
Five lines are the whole app. Here is what each one does:
| Line | What it does |
|---|---|
var builder = WebApplication.CreateBuilder(args); | Prepares the app: reads settings from files and environment variables and sets up the built-in web server. On App Service this is how the app learns which port to listen on, so the code has no port number. |
var app = builder.Build(); | Builds the app from those settings. After this line you add the pages. |
app.MapGet("/", () => "Hello from Azure Web App"); | When a browser asks for the home page, send back this plain text. |
app.MapGet("/health", () => Results.Ok("Healthy")); | Answers /health with status 200 (OK) and the word Healthy as JSON. That is why the browser shows it in quotes. |
app.Run(); | Starts the server and keeps it running until Azure or you stop it. |
And here is how the choices on the portal form show up in your code:
| Portal choice | Effect on the app | What to do |
|---|---|---|
| Runtime stack | Sets the .NET version Azure runs | Match the version in your project file (net10.0 here) |
| Operating system | Changes the machine under the app | Modern .NET runs on both; .NET Framework 4.8 needs Windows |
| Publish: Code | Azure runs your built files | Deploy the output of dotnet publish, as below |
| Publish: Container | Azure runs your Docker image | Build and push an image instead of a zip |
| Region | Sets how far the app is from visitors | Pick the one nearest your users |
| Name | Sets the default address | Nothing in code; links to the site use it |
Deploy the App to Your Azure Web App
Three commands send it to Azure. We ran them against a Free F1 web app, and the site answered with the greeting a few seconds later. Run them from inside the HelloAzure folder. First build the release files into a publish folder:
dotnet publish -c Release -o publishZip what is inside that folder:
Compress-Archive -Path publish\* -DestinationPath app.zip -ForceUpload the zip to the web app:
az webapp deploy --resource-group rg-webapp-demo --name mywebapp-12345 --src-path app.zip --type zipWait for RuntimeSuccessful in the output, then open the site. The welcome page is gone and you see Hello from Azure Web App. Add /health to the address to see "Healthy".
Clean Up So Nothing Keeps Billing
Deleting the resource group removes the web app and the plan together. Check what is in it first:
az resource list --resource-group rg-webapp-demo --output tableThen delete the group:
az group delete --name rg-webapp-demo --yes --no-waitIn the portal, open the resource group and select Delete resource group. This cannot be undone, so read the group name before you confirm.
Essential Commands Cheatsheet
The Azure CLI commands you will use most around a web app. Every one was checked against Azure CLI 2.91. Replace the example names with yours.
| Task | Command |
|---|---|
| Account and subscription | |
| Sign in | az login |
| Show the subscription in use | az account show --output table |
| List all your subscriptions | az account list --output table |
| Switch subscription | az account set --subscription "<name or ID>" |
| Resource group | |
| Create one | az group create --name rg-webapp-demo --location canadacentral |
| List them | az group list --output table |
| See what is inside | az resource list --resource-group rg-webapp-demo --output table |
| Web app | |
| List your web apps | az webapp list --output table |
| Print the address | az webapp show --name mywebapp-12345 --resource-group rg-webapp-demo --query defaultHostName --output tsv |
| Open it in the browser | az webapp browse --name mywebapp-12345 --resource-group rg-webapp-demo |
| Restart it | az webapp restart --name mywebapp-12345 --resource-group rg-webapp-demo |
| Stop it (a paid plan still bills) | az webapp stop --name mywebapp-12345 --resource-group rg-webapp-demo |
| Watch its live log | az webapp log tail --name mywebapp-12345 --resource-group rg-webapp-demo |
| App Service plan | |
| List your plans | az appservice plan list --output table |
| Show one plan and its tier | az appservice plan show --name plan-webapp-demo --resource-group rg-webapp-demo |
| Move to Basic (starts billing) | az appservice plan update --name plan-webapp-demo --resource-group rg-webapp-demo --sku B1 |
| Clean up | |
| Delete everything in the group | az group delete --name rg-webapp-demo --yes --no-wait |
Comparison Tables
Subscription vs Resource Group
These two are mixed up more than any other pair. Here is what is true and what is not:
| Common belief | What is true | Why |
|---|---|---|
| “A subscription is just a folder” | A subscription is the billing and access boundary | Costs are charged to a subscription |
| “The resource group pays” | A resource group only organizes | It is a project folder and is free |
| “A resource can be in two subscriptions” | Each resource belongs to one subscription and one group | Billing and permissions need one clear owner |
| “Resource groups are optional” | Every web app must be in a resource group | The form will not let you skip it |
Code vs Container vs Static Web Apps
| Option | What you deliver | Best for |
|---|---|---|
| Web App, Publish: Code | Your built app files | Normal .NET, Java, Node.js, Python and PHP apps (this guide) |
| Web App, Publish: Container | A Docker image | Apps that need software the built-in runtimes lack |
| Azure Static Web Apps | HTML, CSS and JavaScript, plus optional small APIs | Front-end only sites. A separate service with its own form, not a Web App option |
Windows vs Linux
| Choice | Use it when | Watch out for |
|---|---|---|
| Linux | Most new apps, and any Python or PHP app | .NET Framework 4.8 sites do not run here |
| Windows | Older ASP.NET sites on .NET Framework 4.8 | No built-in Python or PHP |
| Either | Modern .NET, Node.js and Java | Pick by what the rest of the app needs |
| Container | The runtime you need is not built in | You keep the image updated yourself |
Troubleshooting Table: Common Problems When You Create an Azure Web App
| Problem | Cause | Fix |
|---|---|---|
| The name is not available | Someone already uses that address | Add a suffix, or leave unique default hostname switched on |
| The address is long and random | Unique default hostname adds a hash and the region | Normal. Add a custom domain on a paid tier for a clean address |
| The runtime you want is missing | It does not exist on the selected operating system, or the version is out of support | Switch between Windows and Linux, or pick a supported version |
| You cannot create anything | No active subscription, or your account lacks permission on it | Check the subscription, or ask for the Contributor role |
| The cost lands on the wrong account | The wrong subscription was selected | Check choice 01 first; in the CLI run az account show |
| You cannot find the app later | Resources spread over many groups | Use one resource group per project with a clear name |
| The ASP.NET option switches you to Windows | .NET Framework 4.8 runs only on Windows | Use modern .NET (ASP.NET Core) to keep Linux |
| The portal looks different from a guide | Theme and menu are personal settings, and the portal changes | Use the search bar at the top and type “App Services” |
| “Operation cannot be completed without additional quota” | Your subscription has no quota for that tier in that region | Try another region, or request more quota on the Quotas page |
| “The selected region is currently not accepting new customers” | Azure limits who can create resources in some busy regions | Choose a different region |
| The bill is higher than expected | A paid plan was left running, or the app was only stopped | Delete the plan or the whole resource group |
| The app is in the wrong region | Region cannot be changed after creation | Create a new app in the right region and move the code |
| The first visit is slow | Free tier apps sleep when idle | Normal on Free F1. Always On needs Basic or higher |
Final Mental Model
If you remember one picture, make it this one. Read it from the top: each line sits inside the one above it.
Azure account
- Subscription: who pays, and who may change things
- Resource group: the project folder
- App Service plan: the machine you rent (region, operating system, tier). This is what you pay for.
- Web app: your site, running on that plan
- Name: the default address, unique across Azure
- Publish: Code or Container
- Runtime: .NET, Node.js, Java, Python or PHP
- Your code: sent with
az webapp deploy
- Resource group: the project folder
Key takeaways
- Subscription pays, resource group organizes, App Service plan runs, web app is your site.
- The name becomes the address; the portal now adds a random part and the region by default.
- Choose Code, .NET 10 (LTS), Linux unless you need Windows, and a region near your users.
- Free F1 costs nothing. Paid plans bill every hour, stopped or not.
- In the CLI, always write
--skuand the operating system. - Delete the resource group when you finish practising.
Azure Web App FAQ
Is an Azure Web App free?
It can be. The Free F1 plan has no charge and allows 60 CPU minutes per day, 1 GB of memory and 1 GB of storage. It has no custom domain and the app sleeps when idle.
What is the difference between a Web App and an App Service plan?
The plan is the rented computer and sets the price. The web app is the site that runs on it. Several web apps can share one plan.
Should I choose Windows or Linux?
Linux for most new apps, and it is the only choice for the built-in Python and PHP runtimes. Choose Windows for older ASP.NET sites that need .NET Framework 4.8.
Can I change the region or name later?
No. Both are fixed when the app is created. To change either one, create a new web app and move your code and settings to it.
Does stopping the web app stop the charges?
No. You pay for the App Service plan for as long as it exists. Delete the plan, or the resource group, to stop the cost.
Official references: App Service overview, App Service plans, the ASP.NET Core quickstart, unique default hostnames and the .NET support policy.
Related Guides on infotechtu.com
Share this guide
Get new guides by email
One short email when a new guide is out. Unsubscribe at any time.
