How to Create a SharePoint Subsite Using a WSP Template with Power Automate

Share this post on:

In SharePoint, subsites provide a way to structure and organize content within a site collection. If you frequently create similar subsites, using a WSP (Windows SharePoint Solution Package) template can simplify the process. Power Automate can then automate subsite creation using this template.

Prerequisites:

  1. A SharePoint Online environment with administrative privileges.
  2. Power Automate access with the Site Admin permissions to create subsites.

Step 1: Save a SharePoint Site as a WSP Template

To create a reusable WSP template from an existing site:

  1. Navigate to the Source Site
    • Go to the SharePoint site that you want to save as a template.
  2. Access Site Settings
    • Click the gear icon > Site Settings.
  3. Enable “Save Site as Template” (if missing)
    • If you don’t see Save Site as Template, activate it using PowerShell:
Powershell :

Enable-SPFeature -Identity "SaveSiteAsTemplate" -Url https://yourtenant.sharepoint.com/sites/yoursite
  1. Save the Site as a Template
    • Under Site Actions, click Save site as template.
A Power Automate flow that sends an HTTP request to SharePoint to create a new web or subsite using a specific template. The "Site Address" and "Uri" parameters are set, and the body defines the details of the new site including the template used, URL, and language.

Enter a template name and filename (e.g., ProjectTemplate).

A screenshot from SharePoint where a solution file (.wsp) is being uploaded. The user is selecting the "Choose File" option to upload a SharePoint solution to the site.

Check Include Content if you want to keep lists, libraries, and settings.

  • Click OK, then Save.
    5. Download the WSP File
    • Navigate to Site Settings > Solutions (under Web Designer Galleries).
    • Locate your WSP file, click Download, and save it for later use.

Step 2: Upload and Activate the WSP Template

  1. Go to the SharePoint Solution Gallery
    • Open the destination site collection.
    • Navigate to Site Settings > Solutions.
  2. Upload the WSP File
    Click Upload Solution, select your .wsp file, and click OK.
A "Save as Template" settings page within SharePoint where users can save a site as a template. It includes fields for the file name, template name, and description, with the option to include content in the template.
  1. Activate the Solution
  • Click on the uploaded solution and select Activate.
  • The template is now ready to use for subsite creation.

Step 3: Create a Subsite Using Power Automate

Now, let’s use Power Automate to create a subsite based on the WSP template.

1. Create a New Flow in Power Automate

  • Go to Power Automate and click New Flow > Instant Cloud Flow.
  • Select Manually Trigger a Flow (or trigger it based on an event, such as a new list item).

2. Add an HTTP Request Action

  • Click + New Step and search for HTTP.
  • Choose Send an HTTP request to SharePoint.

3. Configure the HTTP Request

  • Use the following settings:
Method: POST
Site Address: Choose the parent site.
URI: _api/web/webs
Headers:

{ 
"Accept": "application/json;odata=verbose",

  "Content-Type": "application/json;odata=verbose"
}

Body:
{

  "parameters": {

    "Title": "New Subsite",

    "Url": "new-subsite",

    "WebTemplate": "STS#0",

    "UseSamePermissionsAsParentSite": true,

    "Description": "This is a new subsite created from a template",

    "Language": 1033
}

 screenshot from SharePoint’s Site Settings page showing the option "Save site as template" under the Site Actions section. This option is used to create a reusable template for the site.

If your WSP template has a custom name (e.g., ProjectTemplate), replace with your template name.

Step 4: Save and Test the Flow

  • Click Save and then Test to check if the subsite is created.
  • Go to your SharePoint site and confirm the subsite appears under Site Contents.

Conclusion

By following these steps, you can:

  • Save a SharePoint site as a WSP template
  • Upload and activate the template in the SharePoint solution gallery
  • Use Power Automate to create subsites based on the WSP template

    This approach saves time by automating subsite creation while ensuring consistency across your SharePoint environment.
At 200OK Solutions, we make it easier for businesses to streamline their SharePoint operations with innovative solutions. Our expert team can help you create SharePoint subsites using WSP templates, fully integrated with Power Automate. This seamless process allows for efficient site creation, automation, and management, saving time and resources. Whether you’re looking to build consistent sites across your organization or need a custom solution tailored to your needs, our services ensure a smooth, scalable approach to SharePoint management. Visit our blog to learn more about how we can help you unlock the power of SharePoint with automated workflows and templates

Author: Piyush Solanki

Piyush is a seasoned PHP Tech Lead with 10+ years of experience architecting and delivering scalable web and mobile backend solutions for global brands and fast-growing SMEs. He specializes in PHP, MySQL, CodeIgniter, WordPress, and custom API development, helping businesses modernize legacy systems and launch secure, high-performance digital products.

He collaborates closely with mobile teams building Android & iOS apps , developing RESTful APIs, cloud integrations, and secure payment systems using platforms like Stripe, AWS S3, and OTP/SMS gateways. His work extends across CMS customization, microservices-ready backend architectures, and smooth product deployments across Linux and cloud-based environments.

Piyush also has a strong understanding of modern front-end technologies such as React and TypeScript, enabling him to contribute to full-stack development workflows and advanced admin panels. With a successful delivery track record in the UK market and experience building digital products for sectors like finance, hospitality, retail, consulting, and food services, Piyush is passionate about helping SMEs scale technology teams, improve operational efficiency, and accelerate innovation through backend excellence and digital tools.

View all posts by Piyush Solanki >