Bokeh Web Application

Hello everyone,

I am a civil engineer trying to build simple apps (compared to yours!) to calculate and present basic properties. My main dream is creating a simple website and procedure for me to write the python code, design it in Bokeh layouts and upload. So, I can concentrate on coding the tools.

However, bokeh server thing is out of my capabilities. When I saw bokeh demo page, it looked so easy, creating the layout was easy in fact. However, naively, I though it would be very simple like uploading something.

Now, as you understand my minimum needs, what would you recommend me? I don’t know anything but a little Python and Matlab. So HTML codes are very strange to me. However, if I need to do that for my webpage procedure, I will try to learn.But I wish there is a way for easier implementation.
(Easier for a rookie like me.)

1 Like

I’m still learning as well, but might have some ideas:
For me the major questions are:

  1. Are you trying to embed bokeh content into an existing website?
  2. Do you want to update the plots dynamically from python/backend?

Depending on the answers different things are possible, here’s the relevant documentation (you probably already saw this):

If you already host your website somewhere, it would be easiest to embed bokeh content into the existing html without backing it with a bokeh server (meaning you cannot update it dynamically from python). But it’s hard to advise (for me) without further information.

Consider this post, and links,

Thank you for the answer.

I need dynamically updated chart, therefore, embedding a static content is not valid for my case. My ideal case would be a simple website with different applications, but I think I need a server for that and even if I get the server, it is not very easy to that for me. So, if you can help me, it would be greatly appreciated.

Thanks. Links are not working and I am not sure it covers my case. OK, s/he used Django, but that’s all for me.
Lets admit it. That part of Bokeh is not well documented. We can create good apps that work on our local hosts with very responsive interface thanks to Column Data Sources, however, publishing it on internet like is not easy.

Recommended reading: The bokeh directory format: This gives you most flexibility in my perspective. You have one ‘index.html’ and then you can embed bokeh content into this template in quite flexible ways (see also: .

Also in terms of deployment check . Deploying some server with nginx as reverse proxy is a pretty standard way of doing things. Make sure to work through the whole ‘deployment scenarios’ chapter (e.g. security).

I needed some time to understand the different ways bokeh provides for embedding and serving bokeh content, but once I understood it and found the best approach for my use-case I’m quite happy with it. I hope this helps and please let me know the part(s) you are struggling with!

1 Like

If you Google “heroku deployment of bokeh app” you should find at least ten good guides step for step how to deploy a bokeh app to the general Internet.

@Johannes, thank you for detailed answer. Let me digest this information and come back to you with my results and struggles. Following sentence gave me hope :slight_smile:

once I understood it and found the best approach for my use-case I’m quite happy with it

I have managed to deploy an app to heroku, however, it is not sustainable for me since I am planning to deploy many engineering apps for people without any expected income. Therefore, I am looking for an option where I can deploy this apps in cheapest way and hopefully in my website.
You can find the link for my heroku app. @Johannes maybe you can check too.
BD Tunnel Deformation
And, thanks for all answers again.

Where do you run your website? What framework does it run on? With what you want to achieve you will need to run a bokeh server (due to the dynamic behavior).

I guess you could deploy a bokeh/nginx stack on your server (if you have one) using e.g. docker. How to embed the bokeh content depends on your website framework.