HomeDeveloppementSharePoint Site Templates: Extend your SharePoint sites

SharePoint Site Templates: Extend your SharePoint sites

SharePoint offers a flexible platform for collaboration and information management, and customizing SharePoint sites to meet specific organizational needs can significantly enhance productivity and user experience. In this article, we’ll explore how to create, edit, and implement custom SharePoint site templates using modern tools and practices.

Template Creation

Step 1: Creating a Base SharePoint Site

The journey to a custom SharePoint site template is easier by going through creation of a SharePoint site that serves as your template baseline. This site should be configured with the desired structure, content, settings, and components that you wish to replicate across future sites.

Step 2: Extracting the Template Code

Once your SharePoint site is configured, the next step is to extract the site template code. This is done using PowerShell with the help of the PnP PowerShell library, which is a powerful toolset that simplifies many SharePoint management tasks. The specific cmdlet used for this purpose is Get-PnPProvisioningTemplate. This cmdlet helps you to generate an XML or JSON provisioning template that captures the configuration of your site.

powershellCopy code# Connect to your SharePoint Online
Connect-PnPOnline -Url https://yourtenant.sharepoint.com/sites/yoursite -UseWebLogin

# Generate the provisioning template
Get-PnPProvisioningTemplate -Out "path/to/your/template.xml"

Edit the Template Easily

Step 3: Editing the Template

Modifying a SharePoint site template directly in XML or JSON format can be challenging and error-prone. To simplify this process, you can use a visual editor like Site Designer. This tool provides a user-friendly interface to visually design or edit your SharePoint site templates. You can paste the JSON code of your template into the tool and make changes through its graphical interface, which is less prone to errors and more intuitive than direct code edits.

Create the Template

Step 4: Creating the Site Template

After editing your template, the final step is to create a deployable SharePoint site template. This can be accomplished by following Microsoft’s guide on creating site designs and site scripts. Site designs allow you to apply a set of actions like creating lists or setting themes, which are defined in a JSON script.

  "$schema": "schema.json",
  "actions": [
      "verb": "applyTheme",
      "themeName": "Contoso Theme"
      "verb": "createSPList",
      "listName": "Project Documents",
      "templateType": 101
  "bindata": {},
  "version": 1

Extending Capabilities with Power Automate

Beyond static site features, SharePoint templates can be enhanced with automation using Power Automate. This allows for dynamic behaviors such as auto-archiving documents, sending notifications when new content is added, or even integrating with external APIs for enhanced data processing or workflow management.

Use Case 1: Automated Document Management

Scenario: Whenever a new project site is created, automatically set up a document library with custom metadata and start a flow that archives documents when they reach a certain age.

Solution: Configure a site design that includes a site script for creating a document library. Then, trigger a Power Automate flow to apply retention policies and archive old documents.

Use Case 2: Dynamic Onboarding Process

Scenario: On creation of a new department site, initiate an onboarding process where new team members receive personalized emails with resources and setup tasks are automatically tracked in a SharePoint list.

Solution: Use a site design to create a specific list to track onboarding tasks. A Power Automate flow can then be initiated to send out welcome emails to new team members and update the list as they complete each onboarding step.

Use Case 3: Real-time Data Integration

Scenario: For each new sales site, integrate real-time sales data from external CRM systems into a SharePoint list to keep track of client interactions and sales figures.

Solution: Implement a site design to create a sales data list. Set up a Power Automate flow to pull data periodically from the CRM system and populate the SharePoint list with the latest figures.

Example of code

Deployment and Reuse

Once created, these templates can be managed and deployed across your organization to ensure consistency and compliance in site creation. They can be used by thirdparty tool that provision sites for end user like AvePoint Cloud Governance.

AvePoint Cloud Governance is self-service user application that will allow you to define approval flow (or not) to create Teams, SharePoint, Guest users.

Through permission / purpose renewal, you guarantee that a workspace is still useful and that helps Microsoft 365 Copilot good deployment.


Custom SharePoint site templates are a powerful way to standardize site deployments, ensure compliance, and enhance productivity across your organization. By using tools like PowerShell, Site Designer (online), and Power Automate, you can create customized sites template that meet the unique needs of your organization.

- Advertisement -


Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.



Recent Comments