Showing results for 
Search instead for 
Did you mean: 
Helper I
Helper I

Flow to create subsite with custom webtemplate


I have a custom webtemplate i have saved as wsp file and uploadet it to my site collection.

I can use that webtemplate just fine if i create a manuel subsite and its showing it under custom webtemplates like her


The CustomWebtemplateID is listed here image.png and i try to use this ID to create the site.


Her is the flow - When e new item is created then



If i change my WebTemplate to STS#0 then new modern page is created just fine, but if i use my TemplateID then i get error (Status Code: 400)



the error is here:


"status": 400,
"message": "<?xml version=\"1.0\" encoding=\"utf-8\"?><m:error xmlns:m=\"\"><m:code>-2147024809, System.ArgumentException</m:code><m:message xml:lang=\"da-DK\">The file or arguments are not valid for the web template '{6B125B90-3015-4813-8404-C0CB31B122AE}#VAB-Skabelon'.&#xD;\nParameter name: WebTemplate</m:message></m:error>\r\nclientRequestId: 07142bab-e822-4098-be1f-8454cce0ff58\r\nserviceRequestId: d97ca79e-90fd-0000-376a-a308dc61c756",
"errors": []
I hope i was clear and i hope someone can tell me why i get this error when custom template is work great manually.




Frequent Visitor

It’s seemed to be okay, but i have noticed that the single quotation at the front of the WebTemplate ID is missing. can you fix and try it again? Actually, I have got a similar situaltion with you. My issue was WebTemplaID value was wrong.  I hope it will help.

Frequent Visitor

There is an apostrophe missing in WebTemplate value. Try put


with extra ' after :

Helper I
Helper I

Hello all, i'm facing a similar issue and i would appreciate your help. I'm trying to create a subsite based on a template (i would like to use the template that i have created with this ID --> 

{B01398ED-CC81-45A2-8813-70F908EECFE5}#New Bank Template) ), but i cannot seem to get it to work. So i tried to create a subsite from an existing template (STS#0) and again it shows the same error message. Please check below my code and advise. 

Screen Shot 2020-11-18 at 5.35.15 PM.pngScreen Shot 2020-11-18 at 5.36.32 PM.pngScreen Shot 2020-11-18 at 5.36.52 PM.pngScreen Shot 2020-11-18 at 5.37.01 PM.png

Missing commas?

You should separate every parameter with ",", in your case there is no comma after Description and WebTemplate.

Try it 🙂

Helpful resources

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Users online (1,693)