# Embed Kibana (v5.2) Visualization in iFrame X-Frame-Options

**URL:** https://discuss.elastic.co/t/embed-kibana-v5-2-visualization-in-iframe-x-frame-options/95942
**Category:** Kibana
**Created:** [August 4, 2017, 6:48pm UTC](https://discuss.elastic.co/t/embed-kibana-v5-2-visualization-in-iframe-x-frame-options/95942 "2017-08-04T18:48:07Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![jdsalingerjr](https://avatars.discourse-cdn.com/v4/letter/j/8baadc/32.png) [@jdsalingerjr](https://discuss.elastic.co/u/jdsalingerjr)
#### Post date: [August 4, 2017, 6:48pm UTC](https://discuss.elastic.co/t/embed-kibana-v5-2-visualization-in-iframe-x-frame-options/95942/1 "2017-08-04T18:48:07Z")

</div>

I am trying to embed a Kibana Visualization into an external page using angular. I've looked at a number of different threads and none of them seem to answer what I am looking for:

- [embedding-kibana-visulaization-using-iframe](https://discuss.elastic.co/t/embedding-kibana-visulaization-using-iframe/2444)
- [auto-authenticating-to-iframe-embedded-kibana-dashboard](https://discuss.elastic.co/t/auto-authenticating-to-iframe-embedded-kibana-dashboard/46091)
- [list-all-kibana-embedded-iframe-urls](https://discuss.elastic.co/t/list-all-kibana-embedded-iframe-urls/81128/2)
- [challenges-embedding-kibana-visualizations-in-elasticsearch--site-plugin](https://discuss.elastic.co/t/challenges-embedding-kibana-visualizations-in-elasticsearch--site-plugin/24900/3)
- [auto-authenticate-kibana-5-0-dashboard-embedded-in-iframe](https://discuss.elastic.co/t/auto-authenticate-kibana-5-0-dashboard-embedded-in-iframe/68457)
- [embed-kibana-visulaization-url-on-webpage](https://discuss.elastic.co/t/embed-kibana-visulaization-url-on-webpage/66483)
- [embed-kibana-dashboard-or-some-chart-in-external-portal](https://discuss.elastic.co/t/embed-kibana-dashboard-or-some-chart-in-external-portal/32476)

The angular code I'm using is the following:

```
<iframe
    class="dashboard-iframe"
    [src]="(visualizationUrl | safe)"
    height="600" width="800"
    >
</iframe>

```

The visualizationUrl is something like:

```
// Copied from "Emedded iFrame" under "Shared Saved Visualization" 
visualizationUrl = `https://my-proxy.sitting.in-front-of.elastic-and-kibana.com/_plugin/kibana/app/kibana#/visualize/my-viz-name?embed=true&_g=some-js-stuff`

```

When I load this into Chrome I get the following in the console:

```
Refused to display 'https://my-proxy.sitting.in-front-of.elastic-and-kibana.com/_plugin/kibana/app/kibana#/visualize/my-viz-name?embed=true&_g=some-js-stuff' in a frame because it set 'X-Frame-Options' to 'sameorigin'.

```

How do I change it so that it allows my domain?

---

<div class="post-metadata">

### Author: ![spalger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spalger/32/14092_2.png) [@spalger](https://discuss.elastic.co/u/spalger)
#### Post date: [August 4, 2017, 7:04pm UTC](https://discuss.elastic.co/t/embed-kibana-v5-2-visualization-in-iframe-x-frame-options/95942/2 "2017-08-04T19:04:09Z")

</div>

A [pull request just went into master](https://github.com/elastic/kibana/pull/13045) to make this configurable in Kibana but hasn't been released yet, so the `X-Frame-Options` header must be getting set by your proxy. You'll have to adjust the options there to allow embedding on your desired domain.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [September 1, 2017, 7:04pm UTC](https://discuss.elastic.co/t/embed-kibana-v5-2-visualization-in-iframe-x-frame-options/95942/3 "2017-09-01T19:04:28Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
