Original idea is from this post
-
Open a tab and navigate to the website where you have content to export.
-
Open devtools and switch to the console tab.
-
Copy and paste the following snippet in the console and Chrome should ask you to save the output file
var obj = JSON.stringify(localStorage, null, 4)
var vLink = document.createElement('a')
vBlob = new Blob([obj], {type: "octet/stream"})
vUrl = window.webkitURL.createObjectURL(vBlob);
vLink.setAttribute('href', vUrl);
vLink.setAttribute('download', vUrl.split('/')[2] + '-export.json'); // give you the website name + "export.json"
vLink.click();
- Profit!
Hmm. Nothing happens when I put the first code in. Console just says "undefined". So I can't test the second one to put it back in. This may work but can't export to test the import. Just tried the second one, and it does create a file dialogue, so probably does work.