# Size of document cookies

**URL:** https://discuss.httparchive.org/t/size-of-document-cookies/49
**Category:** Analysis
**Created:** [July 9, 2013, 12:12am UTC](https://discuss.httparchive.org/t/size-of-document-cookies/49 "2013-07-09T00:12:43Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![souders](https://yyz1.discourse-cdn.com/flex035/user_avatar/discuss.httparchive.org/souders/32/1307_2.png) [@souders](https://discuss.httparchive.org/u/souders)
#### Post date: [July 9, 2013, 12:12am UTC](https://discuss.httparchive.org/t/size-of-document-cookies/49/1 "2013-07-09T00:12:44Z")

</div>

```sql
    SELECT  
     NTH(50, quantiles(numbytes)) median,
     NTH(75, quantiles(numbytes)) seventy_fifth,
     NTH(90, quantiles(numbytes)) ninetieth,
     NTH(95, quantiles(numbytes)) ninety_fifth
    FROM (  
      SELECT respCookieLen as numbytes
      FROM [httparchive:runs.latest_requests]
      WHERE firsthtml = true
    )

```

Based on the July 1 2013 crawl:  
 ![](https://yyz1.discourse-cdn.com/flex035/uploads/httparchive/27/35a24feb49c91508.png)

Not as big as I feared. But there are still some big ones out there:

```sql
    select respCookieLen, pageid, url from httparchive:runs.latest_requests 
    where firsthtml=true order by respCookieLen desc limit 10

```

![](https://yyz1.discourse-cdn.com/flex035/uploads/httparchive/28/7b500d31fd89bfc0.png)

My heart skipped a beat when I initially thought the 10th largest cookie was from “[google.com](http://google.com)”. Then I looked closer. 😉

---

<div class="post-metadata">

### Author: ![igrigorik](https://yyz1.discourse-cdn.com/flex035/user_avatar/discuss.httparchive.org/igrigorik/32/925_2.png) [@igrigorik](https://discuss.httparchive.org/u/igrigorik)
#### Post date: [July 9, 2013, 6:52am UTC](https://discuss.httparchive.org/t/size-of-document-cookies/49/2 "2013-07-09T06:52:23Z")

</div>

Well, the good news is, the tail is indeed very long but it decays very quickly! Once you get over 1.5K, we’re looking at single digit numbers of sites (with outliers at 10k). Quick histogram:  
 ![](https://yyz1.discourse-cdn.com/flex035/uploads/httparchive/32/3c3d6a0149eacbea.png)

```sql
SELECT cookie_bucket, COUNT(*) pages FROM (  
  SELECT
    ROUND(respCookieLen/10)*10 cookie_bucket
  FROM [httparchive:runs.latest_requests]
  WHERE firsthtml = true
)
GROUP BY cookie_bucket  
ORDER BY cookie_bucket; 

```
