Level Timer - best way to save scores (times) for multiple levels

Hi, I’m trying to write a script that automatically saves the fastest time a level is completed in and display it within another scene (level select). I also want the time to be displayed in a GUI during the gameplay of the level so they can see it increasing as they play.

I want to make sure the best times are recorded and kept throughout loading several scenes and also when the user re-opens the app.

Should I use DontDestroyOnLoad for a Game Object throughout all scenes? And would I have a static timer variable for each level? Finally, how do I keep the multiple variables saved once I close the app and reopen it so they don’t have to restart each time they open the app?

Thanks a lot.

Not a full answer (heading to bed), but look at PlayerPrefs. That’s what you use to store persistent data to the device. Then you can just call it up and display it whatever you want.