Ask HN: A.foo.com vs. Foo.com/A

8 points by paddw ↗ HN
I feel like the former one has become much more popular recently. Why? AFAIK there is little practical difference, other than CORS being more of a problem with the former as well. Is it just aesthetics?

11 comments

[ 3.0 ms ] story [ 36.0 ms ] thread
GitLab does it so that if you're not logged in, you get bounced from gitlab.com to about.gitlab.com but when you're signed in, you can access the app from gitlab.com without the need for any subdomain name for say app.gitlab.com or the like
This is super confusing.
I think it’s pretty great. You go there and get bounced over to a marketing website. Once you’re logged in, you skip the marketing page entirely.
What if I want to visit the marketing page while being logged in?
I imagine most of their search traffic will take you to about.gitlab.com
What does that achieve compared to bouncing users to gitlab.com/about?
A.foo.com can be served by a different IP address than B.foo.com whereas foo.com/A has to be on the same address as foo.com/B.

If you have different DNS names those functions can be on different servers using different technology. One could be in AWS, one in Azure, another on a mac in your office, another on a CDN, another could be some SAAS vendor operating under your brand.

"whereas foo.com/A has to be on the same address as foo.com/B."

Does it though ? I could always reverse proxy /B to another host, correct ?

It is still going through one server if you reverse proxy. If everything is inside one data center it can perform pretty well but you will lose the performance benefits a CDN or something like that could bring to a subdomain.