Data between Level

I’m implementing a jump game and I want to increase the Death Count and respawn on death.
I first declared a variable in the Charater class, and when I called RestartLevel when I died,
I noticed that the data was blown away.
Where should I declare DeathCount?
GameInstance?
PlayerState?
GameState?

Hello! Here is some linked question https://answers.unrealengine.com/questions/1020611/where-is-it-better-to-place-the-general-logic-of-t.html

Both UGameInstance and UGameInstanceSubsystem are widely used in Epic’s code to implement this kind of singleton manager class.

UGameInstanceSubsystem is relatively new and here’s an official introduction: Programming Subsystems | Live from HQ | Inside Unreal - YouTube