Where can I see all the playerprefs created in the editor?

I know it is not possible to see it directly in the editor, but I want to see those created in the editor (not in build version).
I just created a lot of functions creating and deleting playerprefs and I want to be sure I delete all the useless ones.

Is there a way to see all of them ?

2 Likes

Quick info about Prefs

There are two types of Prefs:

EditorPrefs (Stores and accesses Unity Editor preferences):

  • On macOS, EditorPrefs are stored in ~/Library/Preferences/com.unity3d.UnityEditor5.x.plist.
  • On Windows, EditorPrefs are stored in the registry under the HKCU\Software\Unity Technologies\UnityEditor 5.x key.

PlayerPrefs (Stores and accesses player preferences between game sessions):

  • On macOS PlayerPrefs are stored in ~/Library/Preferences folder, in a file named unity.[company name].[product name].plist, where company and product names are the names set up in Project Settings. The same .plist file is used for both Projects run in the Editor and standalone players.
  • On Windows, PlayerPrefs are stored in the registry under HKCU\Software\[company name]\[product name] key, where company and product names are the names set up in Project Settings.

Using PlayerPrefs.DeleteAll usually removes all keys and values. If you want to see all PlayerPrefs in-editor, you may want to use a third-party asset like Advanced PlayerPrefs Window (paid) or PlayerPrefs Editor (free).

Otherwise, PPs can be found in the Registry (Windows) or in the unity.[company name].[product name].plist file (macOS).

Transparency edit: Corrected the .plist file name in the last sentence.

4 Likes

Okay Thanks I will take a look .

This is frustrating. I am resurecting an old game unity 4.9 using windows 7. It has been years and I do not - but would like to- know all the Playerprefs that get saved. I played the game through and saved so I have a LOT of Playerprefs saved but I do not know where to find them. I have looked in every location suggested in every site I have come across suggesting where they might be. In the windows registry there is no folder of company name and it’s not in users/roaming data. For the love of all that is holy this information is kept SOMEWHERE because the playerprefs ARE being saved and loaded. BUT FROM WHERE? is there some code that could easily just print it out? I mean the info is there so how can I see it? I do NOT want to go through every script and feret out every line of code that saves to playerprefs

1 Like

It’s in the docs:
https://docs.unity3d.com/2020.1/Documentation/ScriptReference/PlayerPrefs.html

My advice though is to never use playerprefs because messing with the Windows registry is pointless and definitely more trouble than it’s worth.

MS Visual Studio has a “find in files” feature. You could easily find every line in every file in one go with the right search. I would definitely find them all and replace them with something else.

1 Like