Iframe Shiny apps to Wordpress


Hello Community,

I found out a little while back that I can combine two of my favourite things (Shiny apps and Wordpress) with a simple Iframe.

With this simple line I get my Shiny App inside a Wordpress page:

[iframe src=“https://jiddualexander.shinyapps.io/junction_app/” width=“100%” height=“1000” frameborder=“0” allowfullscreen=“allowfullscreen”]

Looking through my pink glasses I see mostly positives:

  1. I can have data rich pages in a Wordpress website. Or in other words, I can add simple non-reactive content without making my shiny app more complex.
  2. I can have my one Shiny server (set up Dean Attali style http://deanattali.com/2015/05/09/setup-rstudio-shiny-server-digital-ocean/) run many Apps and Iframe them into multiple websites. Or similar with shinyapps io

Am I missing clear disadvantages, or do you think there are other robust and easy ways to do this? I’d love to hear your comments.

There are also thoughts/potentials that I’m not sure are possible but I’d love to explore with you guys. For example, could you have a user based Wordpress site with login where the Shiny app could also recognise the login?



That’s fine and people commonly do that. However, passing the login would not be possible AFAIK.


We did something similar (embedding a model simulator in a tableau server dashboard).

Login was a bit tricky though.

In the end, we had two options:
1.) Make the Shiny app public, embed that and hope no one noticed or found it.
2.) Force users to use two accounts (once for Tableau, one for Shiny (connected to our company SSO for internal users))

It really wasn’t a decision for us (had to go with #2).
If what was in the app itself was not sensitive in any way (ie, a interactive visual of public or user provided data), I could see going with option 1 though.