How to create/convert html page to Master Page on sharepoint online ( office 365 )

Mohammad Qasim 576 Reputation points
2021-04-10T17:43:35.2+00:00

Hi,

Using Office 365 Sharepoint Online.

I am trying to follow article

"https://www.c-sharpcorner.com/article/create-a-custom-master-page-in-html-for-Sharepoint-online/ " to create custom master page

on Sharepoint online, but as I try to import files on Sharepoint designer 2013 , it gives me "Acces denied error"

How can I import html file to convert into master Page.

Can you help me out this Please.

Solution Required : How to create our own Master page in Sharepoint online, as we can create on On Prem by converting out html page to Sharepoint Master Page

Microsoft 365 and Office | SharePoint Server | Development
{count} votes

Accepted answer
  1. MichaelHan-MSFT 18,126 Reputation points
    2021-04-19T01:45:22.777+00:00

    Hi @Mohammad Qasim ,

    When using command connect-sposervice , you should use the url of admin center. It should be this:

    connect-sposervice  https://tenant-admin.sharepoint.com  
    Set-SPOsite https://tenant.sharepoint.com/sites/yoursite -DenyAddAndCustomizePages 0  
    

2 additional answers

Sort by: Most helpful
  1. trevorseward 11,711 Reputation points
    2021-04-10T19:18:34.343+00:00

    Keep in mind that Modern Team and Communication sites do not use master pages.

    Classic Team/Publishing sites, you need to disable NoScript. You can do this via PowerShell:

    Set-SPOSite -Identity https://tenant.sharepoint.com/sites/mySite -DenyAddAndCustomizePages:$false  
    

    Once you set that, you should then be able to upload your custom master page.

    https://learn.microsoft.com/en-us/powershell/module/sharepoint-online/set-sposite?view=sharepoint-ps


  2. MichaelHan-MSFT 18,126 Reputation points
    2021-04-12T06:10:22.38+00:00

    Hi @Mohammad Qasim ,

    Trevor is right. You need to allow custom script on your SharePoint sites. Please refer to this article for more: https://learn.microsoft.com/en-us/sharepoint/allow-or-prevent-custom-script


    If an Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.