SharePoint Provider hosted App

Ravi Kumar 1 Reputation point


Had a request recently from our client for building a new SharePoint App (SharePoint Online), however, they are reluctant in using Azure. Is there any other way to develop a provider hosted app without the need of using Azure?

Appreciate it if you could lead me in the right direction.



A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
9,868 questions
SharePoint Development
SharePoint Development
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Development: The process of researching, productizing, and refining new or existing technologies.
2,715 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. MichaelHan-MSFT 18,016 Reputation points

    Hi @Ravi Kumar

    Yes, it's possible. The similar question is asked here:

    Q: Can we develop a Provider Hosted App in SharePoint online without using Azure?

    A: Yes, it is possible to develop Provider Hosted App for SharePoint Online without using Azure.


    Lets have step by step procedure.

    Step-1: Register your app using appregnew.aspx

    Login to your SharePoint Online environment and navigate to the following URL for registering any new app on your site.

    Generate Client ID and Client Secret.

    Enter appropriate title for your app, Enter the domain where your app will be hosted and then enter the start up path for the app and click on Create

    Here domain is the server where your source code will be hosted

    Step-2: Record the Client Id and Client Secret key

    After clicking on Create button if your details are valid then you will be redirected to the page where new Client ID and Client Secret Key will be displayed

    Step-3: Create an App solution using visual studio.

    Open visual studio and click File -> New -> Project
    Select Apps for SharePoint and give appropriate name and click OK
    Provide the URL of your SharePoint Online environment and Choose Provider-hosted and click Next
    Once you click Next there will be login window, Login with your Office 365 credential and click OK
    Select “SharePoint Online” and click Next
    Here you can specify which kind of application you want to create, click on Next
    Select the Authentication setting, if you are going to use it for your SharePoint farm itself then you can use Certificate and process the steps for creating the public certificate, or else just select the default selection and click Finish
    Once you click on Finish your app creation part is done and you will be redirected to the default code page of the app. Add some line of sample code over here. Here you will observe then you have two project solution one is ProjectName and other one is ProjectNameWeb
    Step-4: Update your web.config and AppManifest.xml file

    Update web.config with the Client ID and Client Secret Key which we recorded in Step-2.

    Also add into the section of web.config file if it gives some trust level issue.

    Update the AppManifest.xml with the Client Id

    Step-5: Publish your code.

    Now your app is ready with sample code and now its time to publish the code.
    So just right click on the ProjectName and select Publish.
    Once you click on publish you will have publish window, Just create new profile and click Next
    Enter your app Client Id and Client Secret key again here and then click Finish
    Once you are done with entering Client Id and Client Secret Key just click on Deploy your web project and follow your traditional way of publishing and publish your code to the domain which you specified at the time of App registration.

    After successfully publishing your code to your domain just click on Package the app.

    Once you click the Package the app you will be prompted to enter the url of your SharePoint Online where you have registered your app and Client Id, Client Id will be populated but please verify once with your original Client Id, if not same then enter your correct Client Id and click Finish

    Once your app packaging is completed you will have your file which is your app which will be installed on your SharePoint online environment

    Now just upload this app to your app catalog and add to your site from site content. Your Provider Hosted App is ready.

    Each and every step is performed and recorded, so if you face any difficulty please feel free to ask in comment section.

    And here is a blog would be helpful:

    Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link.

    If an Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.