Streamlit Extras is a community-driven collection of useful Streamlit components and utilities designed to extend Streamlit's core functionality. It provides a wide range of 'extras' for common UI patterns, interactivity, and backend integrations that are not natively available in Streamlit. The library is actively maintained with frequent minor releases adding new features and fixing bugs, currently at version 1.4.1.
pip install streamlit-extrasVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to use `stylable_container` to apply custom CSS to a section of your Streamlit app, how to add a `badge`, and how to use `no_footer` to remove the default Streamlit footer. Many other extras follow a similar import and usage pattern.
Review the official `streamlit-extras` documentation and examples for v1.0.0 and later. Test your application thoroughly and adapt custom components to the new architecture if necessary.
Instead of `from streamlit_extras.st_theme import st_theme`, use Streamlit's native `st.set_page_config(layout='wide', initial_sidebar_state='expanded', theme='dark')` and custom CSS via `st.markdown` or `stylable_container` for fine-grained control.
Always consult the documentation or example app (`extras.streamlit.app`) for the specific extra you intend to use. Pay attention to any installation prerequisites or known limitations mentioned for individual extras. Test extras in your target deployment environment.
Pin `streamlit-extras` to a specific minor version in your `requirements.txt` (e.g., `streamlit-extras~=1.4.0`) to prevent unexpected changes when updating. Regularly check the GitHub releases and documentation for updates to extras you rely on.
pip install streamlit-extras
from streamlit_extras.st_toggle_switch import st_toggle_switch
st_toggle_switch(label="My Toggle Switch")