1. Use the eeprom. This is the easiest especially if you want to store a small amount of data. The eeprom is really just using the flash memory on the esp.
2. Use spiffs, which kinda turns the unused flash memory into a tiny ssd drive(oversimplified). Maintaing a Json file for some credentials and last 5 values is a more complex but very well suited and flexible solution.