How to share a Google SERP experiment
or save your cookies, share a NID
by Valentin Pletzer - August 31, 2018
the gist of this article
In order to share an exciting Google SERP experiments with your colleagues all you need to do ist to share the NID cookie value.
the longer read
In 2017, Google engineers tweaked the search algorithm 2,400 times based on the results of more than 270,000 experiments, reviews and live user tests . While I am not sure if this stats also include the layout changes, I know from experience that Google changes those quite a lot as well.
As SEO professionals you probably see those tests quite often as well, because as a responsible SEO you know that you should not be logged in and avoid personalized search results. An easy way to do this, is to use the incognito mode (Chrome) or private browsing (Firefox). After you close this private session your browser basically deletes everything it recorded - including the cookies. And one of those cookies is the key to those Google experiments.
about cookies and a/b experiments
Cookies are often used (next to ip addresses) to divide users into groups, e.g. one group seeing the old version and one group with the experiment. This helps, once a user is part of an experiment, only will see one version of the test so it does not get irritating. A naive approach would be to set key (e.g. userid) and a random number as the value. If your number is even, you are part of group A and if the number is odd, you are part of group B.
Google’s way to group users for experiments
Google is using something very similar for it’s search result experiments. If you don’t have any cookies, the Google servers will send you a set of cookies. A seemingly random string get’s written as value for the cookie with the key NID. At the moment of me writing this article a typical value begins with a number like “137=” and a large amount of random numbers and letters. While this still might be decodable, I don’t know how to decode it (it’s probably not a base64 encoded protocol buffer binary) but this does not really matter, if the only thing you would like to do is to share an experiment with your friends and colleagues.
Google itself describes the NID cookie as a unique ID Google uses to remember your preferences and other information, such as your preferred language (e.g. English), how many search results you wish to have shown per page (e.g. 10 or 20), and whether or not you wish to have Google’s SafeSearch filter turned on. Also, and that is something Google doesn’t share, NID is tied to the experiment you are currently experiencing (or not).
getting and setting the NID cookie tutorial
Therefor all you have to do, is to open the developer console while you are surfing on google.com, open the Application (or Storage) tab and find the NID cookie. Once you found it, you can copy the value for your partners in crime or insert a copy of someone else’s.
when and where does this work
The experiments might be tied to certain environments like browser, operating system, language or even locations. So if you care to share an experimental NID cookie, be sure to share some basic information with it - including the circumstances like a query you used.
In doing so you might leak private information to other people you share the cookie with. So the responsible thing to do is to only share NID values you found in a private / incognito session of your browser.
an live example
At the time of this writing one of Google’s experiments is a test of a sticky header and this is the value I got in my Chrome browser on MacOS:
If you like this tool, experience any problems, have ideas for upgrades or just want to say hi, feel free to contact me on Twitter @VorticonCmdr.