Streamlit Title
Streamlit st.title displays text in title formatting.
The st.title() function in Streamlit displays a large, bold title at the top of your app.
It is typically used for headings, titles, or to highlight important sections of your application.
Need a Streamlit Developer? Click here
Syntax
import streamlit as st
st.title(body, anchor=None, *, help=None, width="stretch")
Example
import streamlit as st
st.title("Welcome to My Streamlit App")
st.title("_Streamlit_ is :blue[cool] :sunglasses:")

Adding Emojis
You can include emojis in your title text by using Unicode characters or emoji shortcodes.
import streamlit as st
st.title("Hello, Streamlit! 🚀")
st.title("Data Analysis 📊 with Streamlit")
st.title("🏆 Welcome to My Dashboard")

Using variable in Title
import streamlit as st
app_name = "My Streamlit App"
st.title(f"Welcome to {app_name}")

Dynamic Title with User Input
we can create a dynamic title that changes based on user input.
import streamlit as st
username = st.text_input("Enter your name:")
if username:
st.title(f"Welcome, {username}!")
else:
st.title("Welcome to My Streamlit App")

Custom Title Styling
While st.title() has a default style, you can customize the appearance of your title using Markdown or HTML.
import streamlit as st
st.markdown("Custom Styled Title
", unsafe_allow_html=True)

st.markdown("Another Custom Title
", unsafe_allow_html=True)

st.markdown("Centered Title
", unsafe_allow_html=True)

st.markdown("""
""", unsafe_allow_html=True)
st.markdown("🔥 Streamlit Dashboard
", unsafe_allow_html=True)

Interactive Titles With State
You can create interactive titles that change based on user actions or application state.
import streamlit as st
if "count" not in st.session_state:
st.session_state.count = 0
if st.button("Click Me"):
st.session_state.count += 1
st.title(f"🔥 Button clicked {st.session_state.count} times!")

The st.title()
function might look simple, but when combined with variables, session state, HTML, and CSS, it becomes a powerful tool for creating beautiful dashboards and interactive UIs.
Learn More About Streamlit: Click Here
Watch Videos on Streamlit: