DS / ML2026.01.20 · 06 min read

Streamlit dashboards for
analytics teams.

No frontend team, no multi-week wait. A working internal dashboard built in an afternoon — and the template I now reuse every time.

§1 The brief

A stakeholder needed to self-serve a specific slice of campaign data — filterable by domain, date range, and channel — without filing a ticket every time the question changed. The "proper" answer was a BI dashboard; the realistic timeline for that, given the existing backlog, was several weeks. The actual need fit in an afternoon.

§2 Why Streamlit over the "proper" BI tool

Streamlit turns a Python analysis script into an interactive web app with almost no additional code — widgets are just function calls, and the whole thing redeploys on save. For an analyst who already has the query and the Pandas transformation written, the gap between "script" and "shareable internal tool" shrinks to almost nothing.

§3 The build

python
import streamlit as st
import pandas as pd

st.set_page_config(layout="wide")
domain = st.sidebar.selectbox("Domain", domains)
date_range = st.sidebar.date_input("Range", [start, end])

# Without @st.cache_data this re-queries on every interaction
df = load_data(domain, date_range)
st.metric("Sessions", f"{df.sessions.sum():,}")
st.line_chart(df.set_index("date")["conversions"])

The whole first version — filters, two charts, one summary table — took under three hours, including the query. The stakeholder had it the same day, and the follow-up requests (a new filter, a different metric) took minutes rather than another sprint cycle.

§4 What I'd reuse — the template

  • A standard sidebar filter pattern (domain, date range, channel) wired to a single cached query function
  • st.cache_data on every data-loading function — the difference between "snappy" and "frustrating" at scale
  • A consistent metric-row-then-chart layout so new dashboards feel familiar immediately

§5 The honest limitations

Streamlit dashboards are not a replacement for a real BI layer at scale — concurrent users, fine-grained access control, and polished design all start to matter past a certain team size. But for the "I need an answer to a specific question, repeatedly, starting today" case, it closes the gap between analysis and tooling faster than anything else I've used.