diff --git a/docs/2-usage/03-read.md b/docs/2-usage/03-read.md
index 979f5000..61be0d54 100644
--- a/docs/2-usage/03-read.md
+++ b/docs/2-usage/03-read.md
@@ -412,13 +412,7 @@ You can read a stream by using the [WebRTC protocol](#webrtc) by visiting the we
http://localhost:8889/mystream
```
-This web page can be embedded into another web page by using an iframe:
-
-```html
-
-```
-
-For more advanced setups, you can create and serve a custom web page by starting from the [source code of the WebRTC read page](https://github.com/bluenviron/mediamtx/blob/{version_tag}/internal/servers/webrtc/read_index.html). In particular, there's a ready-to-use, standalone JavaScript class for reading streams with WebRTC, available in [reader.js](https://github.com/bluenviron/mediamtx/blob/{version_tag}/internal/servers/webrtc/reader.js).
+See [Embed streams in a website](embed-streams-in-a-website) for instructions on how to embed the stream into an external website.
#### Web browsers and HLS
@@ -428,10 +422,4 @@ Web browsers can also read a stream with the [HLS protocol](#hls). Latency is hi
http://localhost:8888/mystream
```
-This web page can be embedded into another web page by using an iframe:
-
-```html
-
-```
-
-For more advanced setups, you can create and serve a custom web page by starting from the [source code of the HLS read page](https://github.com/bluenviron/mediamtx/blob/{version_tag}/internal/servers/hls/index.html).
+See [Embed streams in a website](embed-streams-in-a-website) for instructions on how to embed the stream into an external website.
diff --git a/docs/2-usage/05-authentication.md b/docs/2-usage/05-authentication.md
index 249cdf29..2beac485 100644
--- a/docs/2-usage/05-authentication.md
+++ b/docs/2-usage/05-authentication.md
@@ -256,7 +256,7 @@ Username and password can be passed through the `Authorization: Basic` HTTP head
Authorization: Basic base64(user:pass)
```
-When using a web browser, a dialog is first shown to users, asking for credentials, and then the header is automatically inserted into every request.
+When using a web browser, a dialog is first shown to users, asking for credentials, and then the header is automatically inserted into every request. If you need to automatically fill credentials from a parent web page, see [Embed streams in a website](embed-streams-in-a-website).
If the `Authorization: Basic` header cannot be used (for instance, in software like OBS Studio, which only allows to provide a "Bearer Token"), credentials can be passed through the `Authorization: Bearer` header (i.e. the "Bearer Token" in OBS), where the value is the concatenation of username and password, separated by a colon:
@@ -306,4 +306,6 @@ Authorization: Bearer MY_JWT
In OBS Studio, this is the "Bearer Token" field.
-If the `Authorization: Bearer` token cannot be provided (for instance, with web browsers that directly access MediaMTX and show a credential dialog), credentials can be passed through the `Authorization: Basic` header, by using the token as password and an arbitrary user.
+If the `Authorization: Bearer` token cannot be directly provided (for instance, with web browsers that directly access MediaMTX and show a credential dialog), you can pass the token as password, using an arbitrary user.
+
+In web browsers, if you need to automatically fill credentials from a parent web page, see [Embed streams in a website](embed-streams-in-a-website).
diff --git a/docs/2-usage/16-embed-streams-in-a-website.md b/docs/2-usage/16-embed-streams-in-a-website.md
new file mode 100644
index 00000000..27818a1b
--- /dev/null
+++ b/docs/2-usage/16-embed-streams-in-a-website.md
@@ -0,0 +1,152 @@
+# Embed streams in a website
+
+Live streams can be embedded into an external website by using the WebRTC or HLS protocol. Before embedding, check that the stream is ready and can be accessed with intended protocol by using URLs mentioned in [Read a stream](#read).
+
+## WebRTC
+
+The simplest way to embed a live stream in a web page, using the WebRTC protocol, consists in adding an `