# X-Frame Origin Embed Error

**URL:** <https://meta.discourse.org/t/x-frame-origin-embed-error/35344>\
**Category:** Product Support\
**Created:** [November 7, 2015, 8:51pm UTC](https://meta.discourse.org/t/x-frame-origin-embed-error/35344 "2015-11-07T20:51:09Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![davidbalderston](https://avatars.discourse-cdn.com/v4/letter/d/df788c/32.png) [@davidbalderston](https://meta.discourse.org/u/davidbalderston)\
**Post date:** [November 7, 2015, 8:51pm UTC](https://meta.discourse.org/t/x-frame-origin-embed-error/35344/1 "2015-11-07T20:51:09Z")

</div>

Sorry, I know there have been other topics about this, but I cannot seem to get it figured out at this point. I have a fresh install of discourse on DigitalOcean using the App, and a Ghost blog. I have the allowed host as the root of my website, and have pasted the code into Ghost, but constantly get the `"Refused to display 'http://community.howtoghost.com/embed/comments?embed_url=https%3A%2F%2Fwww.ghostforbeginners.com%2Fhosting-and-installing-ghost%2F' in a frame because it set 'X-Frame-Options' to 'SAMEORIGIN'."` error.

 ![](https://global.discourse-cdn.com/meta/original/3X/0/0/0060fa59af68e09fd93cf50284ad00db15a48103.png)

From what it looks like, since I have the host in discourse, this shouldn’t be a problem, but after a few days of trying, I cannot get it to work. Have tried both `www.site.com` and just `site.com`, neither work. Does anyone have any ideas? I would really appreciate the help.

Actual Embedded Ghost Code:

```plaintext
<div id='discourse-comments'></div>

<script type="text/javascript">
  DiscourseEmbed = { discourseUrl: 'http://community.howtoghost.com/',
     discourseEmbedUrl: 'https://www.ghostforbeginners.com' + {{url}} };

   (function() {
    var d = document.createElement('script'); d.type = 'text/javascript'; d.async = true;
    d.src = DiscourseEmbed.discourseUrl + 'javascripts/embed.js';
    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(d);
  })();
</script>

```

Thanks,  
David B

---

_[View the full topic](https://meta.discourse.org/t/x-frame-origin-embed-error/35344)._
