How to remove the Xframe Options header in django?

I have a couple of Django sites and someone wanted to show them in an iframe. It was not possible because of the "x-frame-options" header values is always SAMEORIGIN. I could not remove the "x-frame-options" header value no matter what I did.

So finally I decided to do the last resort solution, which is to modify httpd.conf. I added this line:

  Header always set X-Frame-Options ALLOWALL

And it is shown in an iframe.


Remove django.middleware.clickjacking.XFrameOptionsMiddleware from MIDDLEWARE list in settings.py