I had the same requirement, to serve robots.txt. The Clace app deployment platform I have been building has support for this. Create a static_root folder in the the root directory of your Streamlit app code. All files present under that folder, like robots.txt and favicon.ico are served at the base of your app install path.
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Prevent deployed streamlit app from being indexed | 6 | 1153 | July 22, 2023 | |
| How to use "enableXsrfProtection = false" | 4 | 2392 | October 17, 2023 | |
| Modify base rout (root path) in Streamlit | 4 | 7186 | August 20, 2024 | |
| Run Streamlit without root permissions | 5 | 3471 | January 12, 2022 | |
| Streamlit restful app | 29 | 38960 | January 17, 2025 |