optsar,
<!DOCTYPE HTML>
<html>
<head>
<title>Untitled</title>
<meta charset="utf-8">
</head>
<body>
<input type="checkbox" class="stat" name="column-1" value="1" checked >
<input type="checkbox" class="stat" name="column-2" value="2" checked >
<script>
(function(b) {
var e = document.querySelectorAll(b),
a = localStorage.getItem(b),
a = (a = JSON.parse(a)) || (a = {}, localStorage.setItem(b, JSON.stringify(a)));
[].forEach.call(e, function(c, d) {
void 0 !== a[d] && (c.checked = a[d]);
c.addEventListener("change", function() {
a[d] = c.checked;
localStorage.setItem(b, JSON.stringify(a))
})
})
})(".stat");
</script>
</body>
</html>