You can use core data to save all your data and delete it when you want. The code above always create new object of Note class so every time new data you have but when you will try to write with the same name "Note". It always overwrite the old data.