# Hosting Django via ShinyProxy - Refused to display in a frame/ X-Frame-Options

**URL:** <https://support.openanalytics.eu/t/hosting-django-via-shinyproxy-refused-to-display-in-a-frame-x-frame-options/3209>\
**Category:** ShinyProxy\
**Created:** [January 26, 2026, 9:44am UTC](https://support.openanalytics.eu/t/hosting-django-via-shinyproxy-refused-to-display-in-a-frame-x-frame-options/3209 "2026-01-26T09:44:34Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![evilolive](https://support.openanalytics.eu/letter_avatar_proxy/v4/letter/e/ed655f/32.png) [@evilolive](https://support.openanalytics.eu/u/evilolive)\
**Post date:** [January 26, 2026, 9:44am UTC](https://support.openanalytics.eu/t/hosting-django-via-shinyproxy-refused-to-display-in-a-frame-x-frame-options/3209/1 "2026-01-26T09:44:34Z")

</div>

Hello!  
I am trying to host a Django app along with our Shiny apps on ShinyProxy. Unfortunately, I get the following error:

```auto
Refused to display 'https://our_url.com' in a frame because it set 'X-Frame-Options' to 'deny'

```

The section in the application.yml looks like this:

```auto
  - id: djangotest
    display-name: DjangoTest
    container-network: shinyproxy-test-net
    description: Django Testing
    container-image: django-docker
    container-env:
      - DJANGO_SECRET_KEY: 'not_very_secure'
      - DEBUG: True
    container-cmd: ["python3", "/app/manage.py", "runserver", "0.0.0.0:3838"]
    port: 3838
    container-volumes:
      - '/local/dir/:/app/'

```

I am aware that I am still using the Django development server but I just wanted to test this out. I am also new to Django and want to fix secrets etc. once I have a working example.

Thanks for any hints!

---

<div class="post-metadata">

**Author:** ![evilolive](https://support.openanalytics.eu/letter_avatar_proxy/v4/letter/e/ed655f/32.png) [@evilolive](https://support.openanalytics.eu/u/evilolive)\
**Post date:** [February 4, 2026, 8:25am UTC](https://support.openanalytics.eu/t/hosting-django-via-shinyproxy-refused-to-display-in-a-frame-x-frame-options/3209/2 "2026-02-04T08:25:43Z")

</div>

I found the solution. We have to set the x-frame-options in the DJANGO-App, not in ShinyProxy. Otherwise Django refuses to be displayed in an i-frame.  
I put this in my settings.py:

```auto
X_FRAME_OPTIONS = 'SAMEORIGIN'

```
