I am trying to use the code snippet webpart on a SharePoint Online Page. In order to test, I have written a single Header Tag


but for some reason it doesn't render on the page. It only shows the code on the page.

Is there any way to make the code render on the page?

1 Answer 1


The code editor web part is specifically designed to show source code on the web page.

So what you're seeing is by design. If you'd like to enter HTML to be displayed, there is no OOTB method that I'm aware of.

One option is to create a custom SPFx part, which enables to you render any HTML you want.

Of course, this is not a trivial undertaking and requires a developer skill set.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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