Creating an Azure App Service

IntermediateTopic25 min6 min readAzure

Step-by-step guide to creating an Azure App Service web app — runtimes, deployment types, key features, and how to connect CI/CD pipelines.

What Is an Azure App Service?

Azure App Service is a PaaS service for hosting web applications, REST APIs, and backend services. You deploy your code; Azure manages the infrastructure.

Key idea: You focus on the application, not on servers, OS patching, or load balancers.

Core Components

ComponentRole
App ServiceThe actual application instance running your code
App Service PlanDefines compute, memory, networking, and pricing tier

Think of it as: App Service Plan = Infrastructure, App Service = Application.

Default Public URL

Every new App Service automatically gets a globally unique public URL:

https://<app-name>.azurewebsites.net

The name must be globally unique across all of Azure.

Creating an App Service — Step by Step

Step 1: Choose a Publish Type

TypeDescription
CodeDeploy source code directly (most common)
Docker containerRun a containerized application
Static Web AppFrontend-only hosting for SPAs and static sites

Step 2: Choose a Runtime

Supported runtimes on Linux and Windows:

  • Python, Node.js, .NET, Java, PHP, Ruby

Linux is required for Python apps. Windows supports .NET and others.

Step 3: Assign an App Service Plan

  • Select an existing plan or let Azure create a new one
  • The plan determines CPU, memory, and available features
  • All apps on a plan share its resources

Step 4: Configure Deployment (Optional at Creation)

  • Set up CI/CD with GitHub Actions, Azure DevOps, Bitbucket, Local Git, or external Git
  • Can be configured later via Deployment Center

Step 5: Configure Networking

  • Public access enabled by default
  • Can disable public access or enable VNet injection at creation

Key Features

Managed Infrastructure

  • No server management, patching, or configuration
  • Fully abstracted PaaS — you only manage application code

Auto Scaling

  • Scale up → increase VM size (tier change)
  • Scale out → add more instances to handle traffic

High Availability

  • Multiple instances automatically load-balanced
  • Built-in redundancy across the scale unit

Deployment Slots (Important for Exams)

Deployment slots allow you to run multiple versions of your app simultaneously:

  • Production slot — live traffic
  • Staging slot — test new version safely
  • Swap — instantly swap staging → production with zero downtime
  • Rollback — swap back immediately if issues occur

Available on Standard tier and above.

Integration Capabilities

  • Microsoft Entra ID — built-in authentication
  • Virtual Network — connect outbound to private resources
  • On-premises — hybrid connectivity via VNet or hybrid connections

Networking Explained

ScenarioHow
DefaultPublic internet access via azurewebsites.net
VNet IntegrationOutbound access to resources inside a VNet
App Service Environment (ASE)Full VNet isolation (Isolated tier only)
Private EndpointInbound private-only access via VNet IP

Regular App Service with VNet integration is not the same as running inside a VNet — it only provides outbound routing to VNet resources.

Deployment Options

From the Deployment Center in the Azure Portal, you can configure:

SourceDescription
GitHubAuto-deploy via GitHub Actions
Azure DevOpsPipeline-based deployment
BitbucketBranch-based deployment
Local GitPush code via Git from your machine
External GitPublic or private Git repo

Portal Walkthrough Summary

  1. Go to Azure Portal → search Web App → click Create
  2. Enter a globally unique name (this becomes the .azurewebsites.net URL)
  3. Choose Publish type (Code / Docker / Static Web App)
  4. Select Runtime stack (e.g. Python 3.12, .NET, Node.js)
  5. Choose OS (Linux or Windows)
  6. Select Region
  7. Assign or create an App Service Plan (with pricing tier)
  8. Optionally configure Deployment (CI/CD), Networking, Monitoring
  9. Click Review + CreateCreate

After deployment, your app is accessible at the default URL. From the app blade you can:

  • Deployment Center — connect a code source
  • Scale up / Scale out — adjust resources
  • Custom domains — attach your own domain
  • Deployment slots — manage staging/production versions
  • Networking — configure VNet integration or private endpoints

App Service vs. VMs

AspectApp ServiceVirtual Machine
Infra managementAzure-managedYou manage
PatchingAutomaticManual
DeploymentCode/containerYou configure everything
ScalingBuilt-inManual or VMSS
Best forWeb apps and APIsFull control, legacy apps

Key Exam Takeaways

  • Every App Service gets a *.azurewebsites.net URL that must be globally unique
  • Publish types: Code, Docker container, Static Web App
  • App Service Plan = infrastructure; App Service = application
  • Deployment slots require Standard tier or above
  • Swap = instant blue-green deployment; rollback by swapping back
  • VNet integration = outbound connection (not hosting inside VNet)
  • ASE = full VNet hosting (Isolated tier only)

Reference Documentation

Hands-on: Create an App Service Web App

Goal: Deploy a basic web app and practice common AZ-104 operations.

  1. Create an App Service Plan named az104-app-plan.
  2. Choose Linux or Windows based on the runtime you want to practice.
  3. Create a Web App named az104-webapp-<unique>.
  4. Select a runtime stack such as Node, Python, .NET, or PHP.
  5. Browse to the default *.azurewebsites.net URL.
  6. Open Configuration > Application settings and add ENVIRONMENT = lab.
  7. Open Deployment Center and configure a simple GitHub or local Git deployment if available.
  8. Open Scale up and review which features require Basic, Standard, or Premium tiers.
  9. Enable diagnostic logs for application and web server logs.
  10. Stream logs while making a request to the app.

Hands-on: Deployment Slot Swap

  1. Scale the App Service Plan to Standard or higher.
  2. Create a deployment slot named staging.
  3. Deploy a visibly different version to staging.
  4. Open the staging URL and validate it.
  5. Choose Swap from staging to production.
  6. Confirm production now serves the staging version.
  7. Swap back to practice rollback.

More in Microsoft Azure