ASP.NET does this
And apache’s version
https://httpd.apache.org/docs/2.4/mod/mod_auth_form.html
It is probably the easiest way, to map variables to a browser. Few headers, are attached to a browser and a website. Cookies are. And Basic Auth header is.
That is a browser sends the same value, over and over again to the site, and only to that site. Other sites, get and send different values.