Back to the lesson

Cookie lab

Set and read a real cookie, see how a tracker can follow a cookie across sites, and look at your own browser's user agent and fingerprint. The fingerprint is made in your browser and this page sends it nowhere. The cookie is stored in your browser, and your browser sends it back to this site with later requests, as it does for any cookie. Like every page on this site, it counts page views with the Foundation's self-hosted metrics, which use no cookies. The tracker simulation and its sites are made up.

1. Show a cookie

Choose how the cookie should behave, then set it. This page stores it in your browser, as a website would.

How long it lasts
SameSite

What travels on the wire

Every cookie this page can see

NameValue

2. Follow a tracker across sites

Three made-up sites each load code from one made-up ad company, ad.example. Visit them and watch what the ad company can link.

Your browser's cookie rule

VisitSiteCookie sentSeen as

3. Your user agent

Your browser sends this text to every site it talks to. This is the real one from your browser.

    Try another example string (format only)

    4. Your fingerprint

    A fingerprint combines many small details about your browser into one ID. It needs no cookie. These values are read from your browser now.

    DetailYour valueIdentifies

    What if one detail changed?

    How combining details narrows the crowd

    Made-up shares, to show the idea. Out of 1,000,000 visitors, tick the details a tracker collects.

    5. Make your plan

    Your browser

    Settings and menus differ by browser and version, so use your browser's own help to find them. Do not change settings on a school or work device without permission. Tools named here are examples, not recommendations.

    This is a teaching tool. The tracker, sites and numbers in sections 2 and 4 are made up. Dedicated to the public domain under CC0 1.0.