Add a Custom Theme to SharePoint Online


Categories
Tags
How to create a new custom theme/colour palette for use on your SharePoint Online tenant, to help brand your sites more appropriately.

Fluent UI Theme Designer

Fluent UI Theme Designer

  1. Use the Fluent UI Theme Designer (also recommended by Microsoft) to create your colour palette.

  2. Once done, click on export theme > PowerShell. Copy and paste the code to notepad or similar, but add $themepalette = in front of it (we’ll need this in the PowerShell terminal shortly).

    Example:

    $themepalette =@{
    "themePrimary" = "#0078d4";
    "themeLighterAlt" = "#eff6fc";
    "themeLighter" = "#deecf9";
    "themeLight" = "#c7e0f4";
    "themeTertiary" = "#71afe5";
    "themeSecondary" = "#2b88d8";
    "themeDarkAlt" = "#106ebe";
    "themeDark" = "#005a9e";
    "themeDarker" = "#004578";
    "neutralLighterAlt" = "#faf9f8";
    "neutralLighter" = "#f3f2f1";
    "neutralLight" = "#edebe9";
    "neutralQuaternaryAlt" = "#e1dfdd";
    "neutralQuaternary" = "#d0d0d0";
    "neutralTertiaryAlt" = "#c8c6c4";
    "neutralTertiary" = "#a19f9d";
    "neutralSecondary" = "#605e5c";
    "neutralPrimaryAlt" = "#3b3a39";
    "neutralPrimary" = "#323130";
    "neutralDark" = "#201f1e";
    "black" = "#000000";
    "white" = "#ffffff";
    }
    
  3. Follow the link to download and install SharePoint Online Management Shell from the official Microsoft website.

  4. Run SharePoint Online Management Shell to open the terminal and paste in the following command: Connect-SPOService -Url https://myadmindomain.sharepoint.com (where myadmindomain is your SharePoint domain name).

    Connect-SPOService -Url https://myadmindomain.sharepoint.com
    

    PowerShell terminal

    PowerShell terminal

  5. You’ll then get a login prompt from Microsoft, go ahead and login with an admin account for SharePoint.

  6. Next, paste the PowerShell code we generated earlier (including the ‘$themepalette =’ prefix) and press enter.

  7. Now paste Add-SPOTheme -Identity “name of your theme” -Palette $themepalette -IsInverted $false, where “name of your theme” is what you what want to call your theme (this is how it will be labelled in SharePoint), and press enter.

    Add-SPOTheme -Identity "name of your theme" -Palette $themepalette -IsInverted $false
    
  8. To test your new theme, simply visit one of your SharePoint sites and go to the theme settings (Gear Icon > Change the look > Theme), where you should now see your new theme listed amongst the default SharePoint themes.


You can also remove a theme via the terminal by using the following command (used after you’ve connected), where “name of your theme” is the name of the theme you wish to delete:

Remove-SPOTheme -Identity "name of your theme"

Comments

Whether you have feedback, a question, want to share your opinion, or simply want to say thank you - we welcome comments! Please read the disclaimer.

Disclaimer and Legal Information

The use of any content found on or via this website (code, how to guides etc.) is done so at your own risk. We take no responsibility for any issues encountered.

This blog and its authors will not be held responsible for any misuse, reuse, recycled and cited/uncited copies of content from this website by others.

The views and opinions expressed in this blog are those of the author(s) and do not necessarily reflect the position or opinion of any other agency, organisation, employer or company.

Comments are moderated but we do not take any responsibility for any libel or litigation that results from something written in a comment. We reserve the right to reject or delete any comment for any reason whatsoever (abusive, profane, rude etc). Please keep your comments polite and relevant.

We are happy for you to quote and share our content in any reasonable manner, e.g. post links to our blogs on social media, but not in any way that suggests that we, or our authors, endorse you, your use or your views. Nothing negative please.

We appreciate attributions, e.g. a link to our website (www.dragoncode.co.uk).

Thank you – we hope you find the website useful.