localStorage getting empty after 1 week

Hi. I’ve been creating a simple app which saves a few data into window.localStorage[my_key]. However, it’s getting empty after one week so so. That happens even without any action. Is there anything expiring? I really would like to persist forever,…

Thanks in advance,…

We need a LOT more information. What phone OS, device type, cordova version, etc. There are too many things that could contribute to it clearing but we can’t narrow it down with out more information.

iOS 8.1
Latest ionic version with latest cordova version

That is strange, when I was developing with 8.1 (On 8.3 now but it shouldn’t be a difference) I never had my local cache cleared :frowning: Are yo using any specific local storage plugins with angular or cordova?

Nothing different. I have two different apps using window.localStorage and both of them lose their data after one week.

I’ve just found out. The thing is that my iphone is running out of space in disk. And whenever there is a message about that, the OS clears the localStorage. Craaazy!

That’s super handy to know. I wonder how possible it is to warn a user of this… Thank you for giving us some insight on that! Me having the 128GB I probably would never have run into it, hahaha.