Install Blogger Template Safely
A downloaded Blogger template installs in minutes, but a theme backup, a look at the code and a few post-install checks keep the blog safe.

On this page
If you've downloaded a template for your Blogger site, installing it should be a safe process, as long as you start with a theme backup. That gives you a saved copy to restore at any point if something goes wrong. Theme backup and restore live under Theme in Blogger, not in the Settings menu. Blogger's menu labels can change over time.
Back Up, Then Upload the Template
The key step before you restore a new template is to make a backup of your live theme. Blogger Help tells you to open Theme, click the down arrow next to Customize, and then pick Backup and Download. The saved file has an .xml extension, because a Blogger theme is written in XML. Note that this backup does not include your posts: content is saved separately, under Settings > Manage blog > Back up content.
With the backup in place, open the same menu next to Customize, choose Restore, and upload the template file you downloaded. Before uploading, open the file in a text editor and look for anything you did not expect: links to unknown sites hidden in the footer, and long strings of scrambled, encoded JavaScript. Blogger Help notes that blog authors who add code or third-party widgets do so at their own risk, so remove what you cannot explain or choose a different template.
What Changes After Installing
A theme file doesn't carry your whole layout. Gadgets such as the profile, archive or link lists may keep their settings, move to other sections or disappear, because each template defines its own widget areas. If the current layout contains widgets the new file doesn't include, Blogger may ask whether to keep or delete them; keeping them is the safer choice. Afterwards, open Layout and rearrange or re-add gadgets as needed.
Check the blog on a phone as well. Blogger can serve a separate mobile version of the theme, so if a custom template looks right on desktop but not on mobile, review the mobile setting in the menu next to Customize and make sure the custom theme is the one shown to mobile visitors.
Fixing XML Errors and Restoring the Backup
Because a Blogger theme must be well-formed XML, Blogger won't accept a file with markup errors, and it usually reports the line where parsing failed. A common cause is embedded JavaScript or text containing special characters. The XML specification says the ampersand and the left angle bracket must not appear in their literal form except as markup, so write them as & and <, or wrap the script in a CDATA section:
<script>//<![CDATA[
if (a < b && c) { run(); }
//]]></script>
The other usual cause is badly structured elements, such as an opening tag with no closing one. To fix small problems, open Theme > Edit HTML (under the menu next to Customize), go to the flagged line, correct it and save.
If the template still breaks the layout, open Restore again and upload the backup you made at the start. That returns the previous theme, which is why the backup is the first step and the first line of safety.


