☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

Is it possible to save a figure as an image?

Community Support
roinr
roinr

I was wandering if there’s any way (or a workaround) to save a figure to an image without having to use a browser.
Something that will look like:

from bokeh.plotting import figure

f = figure()
f.circle(x=[1, 2, 3], y=[2, 4, 6])

f.save_to_png()
⌁   Link to post
Bryan
Bryan

All Bokeh rendering is actually done by BokehJS. There is no non-JavaScript rendering backend. You can generate png or svg output with export_png and export_svg but these will drive a browser headlessly behind the scenes. It’s not clear whether your concern is avoiding only explicit user interaction with a browser, or with avoiding any browser usage anywhere, even hidden in the background.

⌁   Link to post

End of archived discussion · Replies are disabled