Skip to main content

Host a web application with Azure App service

In this article will learn how to create an environment in App Service for application hosting. Suppose we have developed a website for a business and setting up a new server which may be challenging like you need appropriate hardware, operating system, and web hosting stack. Once all things are done one headache come maintenance, you will be facing this issue when traffic on your site increases day by day, now you will invest again over additional hardware and supporting software. Hosting your web application using Azure App Service makes deploying and managing a web app much easier when compared to managing a physical server. In this module, we will implement and deploy a web app to App Service.

In this article you will learn:
1. Use the Azure portal to create an Azure App Service web app
2. Deploy your code to App Service using FTP

Please create an Azure account if you don’t have please follow the below link.
Create a web app in the Azure portal
Please follow the below steps to create web app, Step by step you will learn, how to create web app for visual studio and will learn to deploy a web application using FTP.
1-    Login to your Azure portal
2-    Click on All services ----- > Filter/Search box with key App Services, a new window will open like below.

App Service on azure
3-    Click on Add button, a window market place will open like below. Choose the Web App and click on over it, now a side window will open where you find some introduction below a create button.
Web App on Azure

4-    In next step you will see the window like below
Process to create Web
Need to understand about available option in above pic.
     a)     App Name: Choose a name for your application it should be unique, for example I have taken “codefaridemo”.
     b)    Subscription: Choose the subscription as per your account SLA, if you are free use then choose free subscription.
    c)     Resource Group: Resource group is like a container which contains services means every service belongs to a particular Resource Group, You have to create Resource Group or chose existing one, in above pic you can see I have select the existing RG.
     d)    OS: Choose operating system as per your requirement.
    e)     Public: Chose as per your requirement I suggest for demo you should choose Code.
    f)      App Service Plane/ Location: In this option you will setup the service plan and location on which location you want to deploy.

5-    Now click on App Service Plan/Location, see below image.
App Service Plan/LocationàCreate Newàhere setup the require field “App Service Plan and Location”à App Service Plan and Pricing
Setup App Service Plan and Location-

6-    When click on pricing the following window will open, you have pay as you go subscription and you are creating this Web App for learning purpose then choose the following pricing model and click on apply.

App Service Price plan-

7-    Now you are ready to create Web App. Finally click on Create button. It will take few times to create.

Ready to create Web

8-    Once your Web App is ready then go on resource. Its looks like below.

Web App Resource overview-codefari

You can see marked area,
URL: on this URL user will access your application
FTP: FTP is not set, to set you ftp click on deployment center (Marked in green).
9-    Now we will setup the ftp, when you click on Deployment Center you will found a lots of option for deployment like Azure Repos, GitHub, BitBucket, LocalGit, Open Drive, Drop Box, External and FTP. Please choose the option FTP other deployment will learn latter.

ftp setup in Web App-codefari
      Setup the ftp as you want and use this one to deploy the application.
For testing created a web application using visual studio 
 1-    Open visual studio
Create a new project in visual studio-
File-Zila Login to deploy web apllication- codefari
Choose web application
2- Create a web application with existing template.
Project create with existing template-
3-    Now publish this application. Right Click on project and choose option Publish.
Publish as file on particular location.
Publish project in file-

4 -    Now using File-Zila we will deploy the web application on Azure Web App.

5-    Login in File-Zilla using ftp credential.

File-Zila Login to deploy web apllication- codefari

6-    Transfer files on root location (wwwroot) 
ftp file location
Running web application on azure

Note: Please give your feedback and you can ask/share question and issue definitely I and my team will respond you. My mail id: