Description
Plotly.rs is a plotting library for Rust, powered by Plotly.js. You build figures in Rust, and any figure can be saved as an interactive HTML file with write_html, which opens in a web browser. The README explains that the Plotly and MathJax JavaScript libraries load from a CDN by default, which keeps the files small. A feature flag can embed the libraries directly in the HTML instead, and a show method opens a plot quickly in the browser. The project also exports static images. The recommended route is the plotly_static backend, which renders figures through a headless browser controlled by WebDriver, using Chrome or Firefox. It can write PNG, JPEG, WEBP, SVG and PDF files. The README notes that this needs a compatible browser and its WebDriver on the system. A reusable StaticExporter makes repeated exports more efficient, and an asynchronous exporter is also available. The library can run inside a WebAssembly environment and includes timeseries downsampling. Crate feature flags control these options. Documentation and interactive examples are in the Plotly.rs book, the examples folder and on docs.rs, and the repository has contributing guidance and a changelog.…
Highlights
- Interactive Plotly.js charts from Rust
- Export to standalone HTML files
- Static image export to PNG, JPEG, WEBP, SVG and PDF
- WebAssembly support
- Timeseries downsampling
Ratings & Reviews
No ratings yet
Be the first to rate Plotly.rs.
People also visit
Plotly.rs FAQ
What is Plotly.rs?
A plotting library for Rust that uses Plotly.js to draw interactive charts.
How do I save a chart?
Use Plot.write_html to save an interactive HTML file that opens in any browser.
Can it export images?
Yes. The recommended plotly_static backend exports PNG, JPEG, WEBP, SVG and PDF, using Chrome or Firefox through WebDriver.
What do I need for static export?
A compatible browser, Chrome or Firefox, and its WebDriver, such as chromedriver or geckodriver, available on the system.
Where are the examples?
In the Plotly.rs book, the examples directory of the repository and on docs.rs.
What are the best Plotly.rs alternatives?
Popular alternatives to Plotly.rs include React-plotly.js, Rust Trade and Vela. See all Plotly.rs alternatives




