I'm not a web developer and I had some basic experiences of web developing (I made my own website some time ago, played around with php, css, some asp.net and other pretty straightforward stuff) but right now I'm asking myself out of pure curiosity: how does stackexchange websites manage to show their questions to google (or any other search engine) as "different webpages" ?

I mean: there are a lot of questions and posts which are surely stored in a database, but regarding the formatting of the page (that is always the same) I suppose each time a new question with relative answers is loaded, something like php's include is used (or ajax calls which load stuff into a stub-page, I never used ajax so I'm quite unsure on how this process works).

TL;DR: how does google see multiple webpages (as if they were looking at static .html pages) even if the contents are fetched from a database per each question?

1 Answer 1


Technically, they all are different pages. The general template used might be the same, but the content within is each different.

The way that Google distinguishes between different webpages is through the URL, and specifically with Stack Exchange, there is a question number in the URL too. So for this question it looks like the number is 61275. The question someone posted before you would be #61274.

For SEO purposes, Stack Exchange also includes some or all of the text of each question in the url too. So this question, you can see is "how-does-stackexchange-websites-manage-to-have-google-see-multiple-questions-as"

The full url ends up having several parts:

webmasters.stackexchange.com << indicates which section of stackexchange the question was posted to

/questions/61275 << the number tells stackexchange which question to look up in the database

/how-does-stackexchange-websites-manage-to-have-google-see-multiple-questions-as << url is typed out for SEO purposes

So it's the unique URL for each question that Google uses to determine each page

Hope that helps!

  • Thanks got it, so it just distinguishes them through the URL and probably caches something as well (I'm referring to the cache page feature).
    – Marco A.
    May 1, 2014 at 18:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.