# Embedded Posts: How to open link in new window?

**URL:** https://meta.discourse.org/t/embedded-posts-how-to-open-link-in-new-window/321027
**Category:** Support
**Created:** [August 10, 2024, 12:59pm UTC](https://meta.discourse.org/t/embedded-posts-how-to-open-link-in-new-window/321027 "2024-08-10T12:59:23Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Brandon007](https://avatars.discourse-cdn.com/v4/letter/b/b4bc9f/32.png) [@Brandon007](https://meta.discourse.org/u/Brandon007)
#### Post date: [August 10, 2024, 12:59pm UTC](https://meta.discourse.org/t/embedded-posts-how-to-open-link-in-new-window/321027/1 "2024-08-10T12:59:23Z")

</div>

Good morning!

With respect to embedding Discourse posts on another site, is there a way to make the embedded posts open the link in a new window/tab? I searched, but couldn’t find anything.

```plaintext
<div id='discourse-comments'></div>
<meta name='discourse-username' content='DISCOURSE_USERNAME'>

<script type="text/javascript">
  DiscourseEmbed = {
    discourseUrl: 'https://community.com/',
    discourseEmbedUrl: 'EMBED_URL',
    // className: 'CLASS_NAME',
  };

  (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>

```
