Hello Streamlit community,
I built a list view component for an internal project because st.selectbox and st.multiselect did not meet my needs.
I wanted it to feel like a native Streamlit widget, for users and developers alike. Its design follows st.selectbox and st.multiselect, and it inherits your app’s theme automatically. Its API follows their signatures too, with extra parameters to customize the list.

Features
- Single or multi selection — with an optional
max_selectionscap. - Grouping — sticky headers; groups can collapse.
- Live search — filters by label as you type. Pin it to keep it in view while the list scrolls.
- Sorting — orders items, group headers, or both, A→Z or Z→A.
- Select all / Deselect all — acts on every row that matches the search, including rows in collapsed groups, and skips disabled rows.
- Add new options — users can enter values that are not in the list; you get the typed string back. Typing the label of an existing option selects that option instead of adding a duplicate.
- Jump to default — scrolls the default selection into view on first render and whenever
defaultchanges. Only the list scrolls, never the page. - Markdown labels and help — the same Markdown Streamlit supports: GFM,
:red[…]colors, badges,:material/icon:,:streamlit:, and emoji. - Returns what you pass in — select a dict, get that dict back, metadata and all.
In the demo app you can try every feature. It also generates the code to use the list view in your own app.
The component is built on Custom Components v2.
Installation
pip install streamlit-listview
# or
uv add streamlit-listview
Basic example
import streamlit as st
from streamlit_listview import listview
framework = listview(
"Select a Python framework",
["Streamlit", "Gradio", "Dash", "Flask", "Shiny"],
selection_mode="single",
key="frameworks",
)
if framework == "Streamlit":
st.write("You selected the right framework!")
elif framework:
st.write("Try again!")
Documentation
The README documents the full API.
Built with
and Streamlit.
Happy Streamlit-ing,
Leland Grunt