Play muted loop video on Streamlit

Viewed 483

I am trying to display a muted loop video on my Streamlit homepage, running on Chrome:

col1, col2 = st.columns([1, 1])

video_html = """
            <video width="320" height="240" autoplay loop>
            <source 
            src="resources/video (online-video-cutter.com).mp4" 
            type="video/mp4" />
            </video>

        """
col2.markdown(video_html, unsafe_allow_html=True)
       

However, as soon as I run the app, I cannot see anything (literally, a blank page).

How can I correctly autoplay the muted video and solve the issue?

1 Answers
Related