Create your first Azure Function

Publish your function to Azure

You can publish your function app to Azure directly from Visual Studio.

  1. In Solution Explorer, right-click the project and select Publish. Choose Create New and then click Publish.

    Publish create new function app

  2. If you haven’t already connected Visual Studio to your Azure subscription, click Add an account…. If you don’t have an Azure subscription you can create one for free.

Create Free Azure Subscription

  1. In the Create App Service dialog, use the Hosting settings as specified in the following table:

    Azure local runtime

    Setting Suggested value Description
    App Name Globally unique name Name that uniquely identifies your new function app.
    Subscription Choose your subscription The Azure subscription to use.
    Resource Group myResourceGroup Name of the resource group in which to create your function app.
    App Service Plan Consumption plan Make sure to choose the Consumption under Size when you create a new plan.
    Storage account Globally unique name Use an existing storage account or create a new one.
  2. Click Create to create a function app in Azure with these settings. After the provisioning is complete, make a note of the Site URL value, which is the address of your function app in Azure.

    Azure local runtime

I ran into an issue I published the function