Forum Discussion
Dempsey9
Aug 18, 2026Copper Contributor
New Outlook Office.js Html body insert fails with error 9011 HtmlSanitizationFailure
I am building an Outlook web add-in for New Outlook on Windows. Calling mailbox.item.body.setSelectedDataAsync, prependAsync, or setAsync with CoercionType.Html fails with HtmlSanitizationFailure code 9011 on an empty HTML compose body, even for minimal Learn-style bold markup. CoercionType.Text works on the same client. Is 9011 a known New Outlook issue? Where is this error documented? What is the supported way to insert formatted HTML from an add-in?
No RepliesBe the first to reply