Click to Rate and Give Feedback
MSDN
MSDN Library
Web Development
SDK Documentation
General Reference
 Deciding Between Custom Templates a...
Community Content
In this section
Statistics Annotations (2)
This page is specific to
The 2007 product release

Other versions are also available for the following:
Deciding Between Custom Templates and Definitions

When choosing whether to create a site template or a site definition, first consider the following issues:

  • Are the changes you need to make simple or complex? If, for example, you need to make only minor changes in the look of certain pages and add a few fields in particular lists, you should create a custom site template. However, if you need to create new content types, add new Web Part definitions, and significantly restructure sites, you should create a custom site definition.

  • Can you deploy changes to the front-end Web server? If you do not have access to the file system of the computers running Windows SharePoint Services, you have no choice but to create a custom site template.

Pros and Cons

Custom site definitions hold the following advantages over custom templates:

  • Data is stored directly on the Web servers, so performance is typically better.

  • A higher level of list customization is possible through direct editing of a Schema.xml file.

  • Certain kinds of customization to sites or lists require use of site definitions, such as introducing new file types, defining view styles, or modifying the Edit menu.

Site definition disadvantages include the following:

  • Customization of site definition requires more effort than creating custom templates.

  • Editing a site definition after it has been deployed is difficult.

  • Doing anything other than adding code can break existing sites.

  • Users cannot apply a SharePoint theme through a site definition.

  • Users cannot create two lists of the same type with different default content.

  • Customizing site definitions requires access to the file system of the front-end Web server.

Custom templates hold the following advantages over customization of site definitions:

  • Custom templates are easy to create.

  • Almost anything that can be done in the user interface can be preserved in the template.

  • Custom templates can be modified without affecting existing sites that have been created from the templates.

  • Custom templates are easy to deploy.

Custom template disadvantages include the following:

  • Custom templates are not created in a development environment.

  • Custom templates are less efficient in large-scale environments.

  • If the site definition on which the custom template is based does not exist on the front-end server or servers, the custom template does not work.

Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Deciding Between Templates and Definitions      Sheyi Adenouga - MSFT   |   Edit   |   Show History

The bullet above that says "Can you deploy changes to the front-end Web server?" should say "you have no choice but to create a custom site template" instead of "you have no choice but to create a custom site definition".

Custom templates are stored in the database and custom site definitions on disk.

Tags What's this?: Add a tag
Flag as ContentBug
Additional Information: Site Customizations: Site Definitions vs. Site Templates      Robert L. Bogue   |   Edit   |   Show History

You may want to see more information about this topic at SharePoint customization: Site Definitions vs. Site Templates (http://my.advisor.com/doc/17614?open&p=1&pid=ztdbms)

Also, note that the article states "Custom templates are less efficient in large-scale environments." This isn't sufficiently clear. The truth is that templates are a bit slower during creation -- largely associated with the additional information -- but during execution SharePoint can't tell the difference between a site/list definition created site/list and one that was created via a template.

Tags What's this?: Add a tag
Flag as ContentBug
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks | Privacy Statement
Page view tracker