All progress in Cookie Clicker is preserved in a save. Save has form of a base64 encoded string, containing all information about the state of the current session.

The save is stored in the web browser's cache, allowing the player to close the tab, web browser or turn off the PC without losing the game progress. Game progress is saved automatically every 60 seconds. It can additionally be saved manually by pressing "Ctrl+S" (this doesn't reset the autosave timer). Whenever the game is saved, a brief notification pops up at the bottom-center of the screen.

Save handlingEdit

Exporting the saveEdit

Orteil allows you to export the save string, either to make a backup or to migrate your game progress to another computer/browser.
To export the save, go to Options menu and click "Export Save". A pop-up window appears, having a long unreadable string highlighted. Copy the string by "Ctrl+C" and paste it into a text file, which you can then store on your computer or USB device.

Saving to fileEdit

Works the same as Exporting the save, it's just more convenient way to do so. It creates a .txt file with the name YournameBakery.txt with the save string already present. This is faster and easier way to back-up your save file on your computer.

Importing the saveEdit

Similarly to exporting, the importing works right the opposite way. Copy a save string you have stored in a text file, paste it into a pop-up window that shows up after clicking "Import Save" button and confirm. The game loads the data from imported save and adjusts the game progress according to the save data.
This may overwrite your current progress.

Loading from fileEdit

Works the same as Importing the save, it's just more convenient way to do so. Browse your computer for a .txt file with save string and import the save to the web browser. This is faster and easier way to load your backed-up save file from your computer.

Wiping the saveEdit

This option removes all data about Cookie Clicker from your browser. All progress is completely discarded, and cannot be retrieved. Only do this if you are sure you have your save exported, or if you are really addicted to the game and this is the only way to break free. There is a pop-up window asking you if you really want to get rid of all your game progress data, to ensure you don't wipe your save by accident.
Wiping the save is an irreversible process, so be very careful.

Disabling autosaveEdit

The Options menu doesn't give you the possibility to disable the autosave feature. However, it is possible to disable autosaving through the console. To disable autosave, type this into the console and press enter:

   Game.prefs.autosave = 0

To enable the autosave, change 0 to 1:

   Game.prefs.autosave = 1

Be careful though, if you don't have autosave enabled and your browser crashes, you can lose a great deal of your progress.

Extending save outputEdit

(This works only by altering the source-code of the game)
The save string can be shown in several different ways, either as string-only, uncompressed string or uncompressed-commented string. To change the save format, find the string Game.toSave=false; and change the "false" value to 1,2 or 3 respectively, for each type of output.
Note that this will not work in console, as the game rewrites the value of Game.toSave back to "false".
This option was added by Orteil probably to test and debug the save behavior.

Save formatEdit

The save uses base64 encoding format, appended with !END! string.[1]This is to ensure portability across all platforms. After removing the !END! appendix, the string can be base64 decoded to a more readable format. The data is structured into several parts. Each part starts by delimiting "|" character (ASCII code 124). Inside each part, the particular data entries (unless they are bitfields) are delimited by a semicolon ";" character. These special characters are used for easier data parsing from the save string.

Parameter name Value example Description
Game version 2.0106 Version of the game which was saved.
Empty part (reserved for future use)
Metadata part
Ascension start 1514764800 Time and date of the current ascension's start.[2]
Legacy start 1514764800 Time and date of the whole game's start.[2]
Last opened 1514764800 Time and date of the time we last opened the game.[2]
Bakery name Yourname String with your name.[3]
Seed abcde 5 lowercase letters with the game seed, defining the behavior of Random Number Generator in your game.
Preferences bitfield part[4]
Particles 0 Show cookies falling down, etc.?
Numbers 1 Show numbers that pop up when clicking the cookie?
Autosave 1 Should the game be saved automatically each 60 seconds? (This cannot be changed in the options.)
Autoupdate 1 info needed
Milk 1 Show milk under big cookie?
Fancy graphics 0 Show fancy graphics?
Closing warning 0 Show the warning when closing the game tab?
Cursors 1 Show your cursors around the big cookie?
Focus 0 Enable defocus to improve performance when window is out of focus?
Number format 1 Display short numbers?
Notifications 0 Hide notifications faster?
Wobbly Cookie 0 Enable big cookie wobbling when clicked?
Monospace 0 Show your cookies using alternative (monospace) font?
Filters 1 Enable CSS filters?
Alternative cookie sound 1 Enable alternative cookie sound when clicked?
Icon crates 1 Show crates around achievement and upgrade icons?
Backup warning 1 Show warning to back up your save when wiping?
Miscellaneous game data part
Cookies in bank 1.2967133988110403e+35 Amount of cookies in bank.[5]
Total cookies earned 7.3567157982352403e+39 Amount of cookies baked all time[5]
Cookie Clicks 5461 Amount of cookie clicks
  1. This string appears as %21END%21, due to UTF-8 encoding.
  2. 2.0 2.1 2.2 This number is a Linux timestamp, which tells the number of milliseconds elapsed since January 1st, 1970 UTC, 00:00:00).
  3. If you have special characters in your name, such as spaces, they are saved normally, without any special encoding (space is saved as ASCII code 32, for example).
  4. Values here are either 0 for OFF, or 1 for ON. These 1s and 0s are not delimited by semicolon.
  5. 5.0 5.1 The number uses the same format as in "short numbers OFF"
Clover sprout
This article is a stub. You can help Cookie Clicker Wiki by expanding it.