I don't know what's being stored in your browser's LocalStorage, but you can always examine it yourself via Chrome's developer tools. (A similar feature exists on Firefox too, although you need to enable the Storage tab in developer tools first.)
For me, all I see there is an entry named se:fkey
that contains a seemingly random 128-bit hex string and what appears to be a Unix timestamp. Apparently, the random string is used as a CSRF token for AJAX requests, and is put into LocalStorage with a timestamp in order to keep it synchronized between tabs. If you like, you can view the unminified version of the code that stores it; look for the bind_fkeyUpdate()
function.
Searching all the JS code used on this page for other mentions of localStorage
(easily done on Firefox dev tools using the "search all files" feature of the Debugger tab), it seems that Stack Exchange's internal click analytics code (search for StackExchange.gps
here) also uses LocalStorage, but only ephemerally to cache data until it can be relayed to the SE servers via AJAX. Thus, in normal use, you probably wouldn't notice it just by inspecting the stored data.
In any case, while such click-tracking analytics code does present some genuine privacy concerns (only somewhat mitigated in this case by the fact that the data isn't going to any third-party servers), the ephemeral use of LocalStorage in the tracking code doesn't really affect those concerns much; such click tracking would be no more or less invasive even if done without using LocalStorage.
Apparently, there also used to be some code in the SE client-side codebase that used LocalStorage to track next/previous button clicks somewhere. All that's now left of that code are the following lines:
// this is needed to reclaim a bunch of localStorage crap from the next/previous button experiment
var cleanupNextAndPreviousButtonState = function () {
try {
localStorage.removeItem('nextPrevTrackState');
localStorage.removeItem('nextPrevTrackState2');
localStorage.removeItem('nextPrevState');
} catch (e) { }
};
Honestly, I have no idea what the original use of those LocalStorage keys was, but all that the remaining code is doing is erasing them if they're still present.
localStorage
data, not an actual indication of how much data is stored. (SQLite is usually configured in such a way that deleted data is not reclaimed immediately, and adds some overhead of its own.) In my case, Chrome tells me that my localStorage database for stackoverflow.com is 24KB, but when I inspect the contents it actually only has two values, totaling less than 1KB. $\endgroup$