Overview
SharePoint Framework (SPFx) is popular for developing the solutions for modern sites in SharePoint Online. However, it is not only limited to the cloud environment. SharePoint Framework development is also supported on SharePoint OnPremise environment (SharePoint 2016 onwards).
In this article, we will explore how we can get our SharePoint 2016 OnPremise environment ready for SharePoint Framework and start developing SPFx client web parts.
Decide Upon SharePoint Framework Version
SharePoint Online follows frequent release cycles as compared to SharePoint OnPremise versions. SharePoint online always uses the latest version of SharePoint Framework. On the other hand, SharePoint 2016 only supports the version with matching server-side dependencies.
Get SharePoint 2016 OnPremise Ready for SPFx
Install SharePoint 2016 Feature Pack 2
In order to get the SharePoint 2016 OnPremise ready for SharePoint Framework development, we need to first install “SharePoint 2016 Feature Pack 2” on the server. If your SharePoint server has a working internet connection and automatic Windows updates are ON, then this should get applied to your server as a part of Windows Update.
Install NodeJS
- Install the latest LTS version from here.
- If you already have NodeJS installed, check the version.
- node -v
Install Code Editor
Install any of the below code editors.
- Visual Studio Code
- Atom
- Webstorm
Install Yeoman and gulp
Run the below command.
- npm install -g yo gulp
Install Yeoman SharePoint Generator
Run the below command.
- npm install -g @microsoft/generator-sharepoint
Develop SharePoint Framework Web Part
Open the command prompt. Create a directory for SPFx solution.
- md spfx-onprem-hello-world
Navigate to the above-created directory.
- cd spfx-onprem-hello-world
Run Yeoman SharePoint Generator to create the solution.
- yo @microsoft/sharepoint
Yeoman generator will present you with the wizard by asking questions about the solution to be created.

Solution Name: Hit Enter to have a default name (spfx-onprem-hello-world in this case) or type in any other name for your solution.
Selected choice: Hit Enter
Target for component: Here, we can select the target environment where we are planning to deploy the client webpart, i.e., SharePoint Online only (latest) / SharePoint 2016 onwards, including 2019 and SharePoint Online / SharePoint 2019 onwards, including SharePoint Online.
Selected choice: SharePoint 2016 onwards, including 2019 and SharePoint Online
Place of files: We may choose to use the same folder or create a subfolder for our solution.
Selected choice: Same folder
Deployment option: Selecting Y will allow the app to deployed instantly to all sites and will be accessible everywhere.
Selected choice: N (install on each site explicitly)
Type of client-side component to create: We can choose to create a client-side webpart.
Selected choice: WebPart
Unless it is SharePoint Online, we do not have an option to create SharePoint extensions in SharePoint OnPremise 2016 version using SPFx generator.
Web part name: Hit Enter to select the default name or type in any other name.
Selected choice: OnPremHelloWorld
Web part description: Hit Enter to select the default description or type in any other value.
Selected choice: SPFx on SharePoint 2016
Framework to use: Select any JavaScript framework to develop the component. Available choices are No JavaScript Framework, React, and Knockout.
Selected choice: React
Yeoman generator will perform scaffolding process to generate the solution. The scaffolding process will take a significant amount of time.
Once the scaffolding process is completed, lock down the version of project dependencies by running the below command.
- npm shrinkwrap
In the command prompt, type the below command to open the solution in code editor of your choice.
- code .
Run the SPFx WebPart
- On the command prompt, type “gulp serve”.
- Open SharePoint site.
- Navigate to /_layouts/15/workbench.aspx.
- Add the webpart to the page.

Troubleshooting
Below are a few common issues and resolutions.
Issue# 1: Workbench does not load
Although you have everything installed and correctly set up, you might face the below issues on running “gulp serve”.
Internet Explorer

Google Chrome

Resolution
In the command prompt, run the below command to resolve the issue.
- set NODE_NO_HTTP2=1
Issue# 2 -
Resolution
“gulp serve” is not running
In some cases, the SharePoint workbench (https://[tenant].sharepoint.com/_layouts/15/workbench.aspx) shows below error although “gulp serve” is running.
Open this URL in the next tab of the browser. Accept the warning message.
https://localhost:4321/temp/manifests.js
Summary
For the future compatibility of the solution, it is recommended to start using SharePoint Framework based development in SharePoint OnPremise. Also, duly note that SPFx solutions created for SharePoint Online might not work for SharePoint OnPremise.

Najmus SaherPosted Aug 21, 2023, 9:45 AM
Thanks , this worked for me. can u please also explain its meaning, n how it works.
Vinay AyinapurapuPosted Jul 5, 2023, 5:58 PM
Is it possible to develop the custom action / app customizer in SP2016? i want to display the banner on selected sites and would like to deploy it as a feature letting the Site Collection admin to enable and disable the banner.
Vinay AyinapurapuPosted Jun 20, 2023, 11:26 PM
Can we develop app customizer in SharePoint 2016?
legendgod legendgodPosted Oct 15, 2019, 1:44 AM
The first step "Install the latest LTS version" is no longer valid. As SP2016 only support SharePoint Framework v1.1.0 and older version Node. There is no official document provide the exact version requirement... but many blogs said old version Node should be used.
Nagarajan ElumalaiPosted Apr 14, 2019, 11:51 PM
Hi am getting an error as Cannot Find Module '@microsoft/sp-property-pane'
K KotreshPosted Jan 8, 2019, 6:12 AM
HI Nanddeep,