SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I provision the search center to my visual studio solution? I have edited my page layout and master page to be able to have the search center in the maincontent of my site collection.

Maby there is a webpart I could just add in my modules element.xml?

Something like following:

  <AllUsersWebPart WebPartZoneID="Left" WebPartOrder="1">
          <webPart xmlns="">

Or is the Search Center in a feature that I could add the feature in my webtemplates onet.xml?

Any kind of help is appreciated alot.

share|improve this question
up vote 2 down vote accepted

The Search Center is a dedicate site template, with its dedicated onet / webtemp entries & definition.

You could easily add one to your site collection by creating a subsite with the template SRCHCENTERLITE#0 / SRCHCENTERLITE#1 or SRCHCEN#0.

Alternatively, you could inject the key search webpart within a dedicated page like in your code sample. You'll need the Core Search Result WebPart, Search Query, Search Paging & Search Refinment to mimic what's available in a search center.

share|improve this answer
How exacly can add SRCHCEN#0 in my site collection? I added it as my basetemplatename and basetemplateid which is 50. What else? – Rohander Feb 22 '13 at 9:29
I think Francois meant you could create a Feature Receiver which will automatically create the Search Center when your feature is activated. Keep in mind, it's a completely separate site (as it's a site template), so when you're in a site and you activate this feature, it'll create a new site somewhere, from the Search Centre template. – James Love Feb 22 '13 at 11:43
Thanks James. My answer was a little bit short on description but indeed, either a feature receiver, or if you are working with publishing site definition, you can add one to your provisioning template. – Francois Verbeeck Feb 23 '13 at 20:53

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.