When I visit hackerweb.app I get the following userAgent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0.3 Safari/605.1.15
When I visit hackerweb.leftium.com I get the following userAgent:
Mozilla/5.0 (iPhone; CPU iPhone OS 14_4_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0.3 Mobile/15E148 Safari/604.1
I am using the exact same device and default Safari browser. What is going on? Interestingly, this happens on a 2020 iPhone SE, but not an iPhone 5. I wasn't able to test any other devices.
In addition, the two sites are ostensibly serving the exact same HTML files. I ran into this while trying to figure out why my fork of https://github.com/cheeaun/hackerweb did not render exactly the same. Due to the different user agent strings, one site defaults to the 'web' theme and the other defaults to the 'ios' theme.
update:
https://hackerweb.app/ defaults to desktop mode. Safari is asking for the desktop version; that is why the user agent is like that. 'Request Mobile Site' gets the expected iOS theme (and thus user agent). I'm still not sure why Safari does this. Perhaps it's because of the ".app" TLD?
I did not accidentally switch it to desktop mode. It's the default mode after 'Clear History and Website Data', no matter which mode I leave it in.
There is a "Request Desktop Website" in "Website Settings" that I must have toggled and forgotten about. This setting is saved even after "Clear History and Website Data."