I am trying to create a custom domain name (already acquired) for an MS Sway site of the form sway.com/<id here>.

The domain service provider uses a dummy page with iframe to display the contents of the actual page as well as to show a ghost domain name in the address bar. It seems sway.com server used to allow this but now is setting X-Frame-Options to SAMEORIGIN and hence the iframe displays nothing.

Has anyone succeeded in doing this or any other way to display a custom domain name for a Sway site?

1 Answer 1


You have to use: https://sway.com/s/{swayId}/embed instead of: https://sway.com/{swayId}].

For instance, you can embed your sway in the index page of your website the following way:

<!DOCTYPE html>
<html lang="fr">
        <title>Your title</title>
        <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
    <frameset rows="100%">
        <frame src="https://sway.com/s/{swayId}/embed" frameborder="0" marginwidth="0" scrolling="no" noresize="noresize"/>

You can of course replace the frame by an iframe:

 <iframe src="https://sway.com/s/{swayId}/embed" frameborder="0" marginheight="0" marginwidth="0" max-width="100%" sandbox="allow-forms allow-modals allow-orientation-lock allow-popups allow-same-origin allow-scripts" scrolling="no" style="border: none; max-width: 100%; max-height: 100vh" allowfullscreen mozallowfullscreen msallowfullscreen webkitallowfullscreen></iframe>
  • Thanks, but neither the regular frame nor the iframe option works when the actual sway domain name is hidden to show the custom domain name.
    – sm535
    Commented May 9, 2018 at 6:44
  • Here is an example of website built with Sway and using domain masking: aufauvre-architecte.com. What do you mean by "does not work"? Commented May 15, 2018 at 13:20
  • Works fine for me with an iframe Commented May 9, 2020 at 15:47

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.