ck3-save-updater

Updating a save: the process…

This page walks a player through bringing an old Crusader Kings III save forward to the game version installed now: ck3update status to see what will happen, then ck3update update to do it. Words the tool coins are explained in the glossary.

The tool never launches the game, and never changes the save you give it unless you ask for --in-place. Even then the original is kept as <name>.bak.ck3, unless you turn backups off (--no-bak, or backup = false in the config file). Every other result is a new file beside your save. (ck3update soak is the one command that starts the game; it is separate, and neither status nor update runs it.)

Before you start

1. See what it will do: status

ck3update status My_Old_Campaign

status prints the plan and writes nothing. Its first line is the verdict: READY, ALREADY CURRENT, NOTHING TO DO or REFUSED. Below it come blocks, each under a header in capitals (what each block holds):

Each built-in rule that will run is judged before anything runs, by its detector (the rule’s own matcher, or the lint check that sees what it fixes). Its PATCHES row says needed with a count (needed: 851 nicknames without text), done (done: none found), or unknown when its detector needs the game folder or a reference save. The detectors need the whole save: the plan reads it once and says how long it took (--no-detect skips it, and the plan reads only the save’s first megabyte). A plan that is already refused does not read it at all (fail early).

The transplant: a save from before the 1.13 map rework going to a 1.20 game loads only with R14-R17. They are selected by default when a reference is present (--transplant auto, or transplant = "auto" in the config file), and the plan says the save needs one when it is not. A reference you name with --reference must be on the save’s own date: on another date the plan refuses and says how to make the right one. --transplant off (or transplant = "off") leaves them out; NOTES then says how to add them.

A save one hotfix behind the game (1.20.1.2 with a 1.20.1.3 game) is ALREADY CURRENT: the same 1.20 version line is assumed compatible, and the plan says so. ck3update help <rule, patch or pack> explains any one of them. --plain prints the plan without colour, for pasting; Configuration says how to change its layout.

2. Update it

ck3update update My_Old_Campaign --dry-run
ck3update update My_Old_Campaign

update --dry-run runs every patch in memory and prints the same plan with each patch’s counts; it writes nothing. update runs the plan status printed: it writes <name>__updated__<game version>.ck3 beside the save, and <output>.report.json beside that (the plan and the counts), and checks the result with lint before it finishes. An output that exists is refused without --force. update takes migrate’s options for the rules (--rules, --custom-faith-as, --portraits-version, --old-game-dir) and exits with the same codes (below).

At a terminal, update prints the plan and then asks “Run the update now? [y/N]”. Nothing is written unless you answer y. A script, a pipe, or output sent to a file runs without asking. --no-ask never asks, and --ask asks even then (it needs a terminal to answer from).

When update does not ask, it skips the checks that only describe the plan. On an old save they never change what runs; they word the PATCHES lines (“needed: 12,702 titles …”). Skipping them saves a minute or two on a large save. The DETECTORS block says they were not run, and each patch’s line after the run gives its counts and what it does. A save already on the game’s version line is still checked, because there the checks decide what runs.

status first is optional, since update prints the same plan. If you do run status first, update reuses its checks: the DETECTORS block says “reused N verdict(s) of the run at HH:MM on this same save”, and the plan takes seconds instead of minutes on a large save. Only checks that found a step needed are reused; the rest are checked again. A different save, a changed option, or a new version of the tool means every check runs again. [cache] plans in the config file turns this off.

Then copy the updated save into the save games folder (if it is not there already), open the launcher with the mods the save names (the report and inspect list them), and load it. Mods made for an older game version can break windows (character, court, tooltips) without touching the save itself: if a window looks wrong, disable the mods that replace that window first. The mods known to misbehave in 1.20 are listed below.

ck3update soak My_Old_Campaign__updated__1.20.1.2.ck3 starts the game, loads the save, lets it run, exits through Exit to Desktop and says whether that went cleanly (soak).

Questions during the update, and --auto

Some patches ask what you want where your old save and the new game disagree. There are two questions.

resources comes up when your old save had a quarry, logging camp, orchard or elephant pen in a province where the game already placed a different resource district. The answers are:

duchies comes up once per update, when a newer game has split some of your counties off into a duchy of their own.

By default the tool moves those counties into the new duchy, as a new game has them.

If you answer “leave”, your counties stay in their old duchy. Going to 1.20, the new duchy then exists with no counties in it. Going to 1.21, the game’s own conversion never adds the duchies that 1.21 introduced, so they are absent from your save. In 1.21 a duchy needs counties to get a market, so either way that duchy has none.

When the tool moves the counties, the new duchy is created unheld, as in a new game, unless one ruler in your realm held the old duchy and all of those counties. Then he gets it. The same question covers counties a new game puts in a different duchy your campaign already has. The answers are:

At a terminal the resources question is asked for each province. Answering a followed by a letter (am, ak, ar) gives that answer to every remaining province. Without a terminal, with --no-ask, or with --dry-run, every question takes its default and nothing is asked.

--auto answers in advance, before the plan is shown:

ck3update update My_Campaign --witness My_Last_120_Save --auto resources=k
ck3update update My_Campaign --witness My_Last_120_Save --auto all=mygame

Entries are read left to right, and a later one wins. --auto all=newgame,resources=m therefore answers m for resources. The plan prints a question : line saying how each question will be answered. The report records every answer and how it was reached. A misspelled question or answer stops the update before anything runs, and the message names the valid ones.

When it refuses

A REFUSED plan ends with each reason, and a fix: line under it:

REFUSED: the gap 1.8.1 -> 1.22.0: no selected pack declares it covers it (a pack's [applies] span); nothing would bring
         the save to the game's version
  fix: a pack in your packs folder whose [applies] declares this span (docs/writing-a-patch.md), or `ck3update migrate`
       with the rules you choose

Do what the fix says, then run status again. Nothing is written while a plan is refused. Troubleshooting covers the common messages.

A save you already updated

A save already on the game’s version line, which the built-in pack’s span does not select (one you updated before, then played), is re-checked: it skips what it already has and gets what is left. Each built-in rule is judged in turn:

--rules still selects (--rules R23 runs R23 alone) and leaves out (--rules all,-R23). The re-check is skipped, and the save is not read past its first megabyte, when the record says this tool version, or a later one, updated it.

The record of a save game

A campaign is updated more than once: a later save of the same ruler, or the next game version. Every save of one campaign carries the same random_seed (its seed) in its gamestate, so after each successful update the tool adds a row to that campaign’s record, games/<random_seed>.toml in the config folder (beside config.toml; CK3SM_CONFIG moves both). --dry-run, status and migrate never write one.

The record’s label is the file name of the first save updated (later updates keep it). Each [[update]] row holds:

A reference save is never recorded, since it belongs to one date, and no part of any save is. A save whose random_seed cannot be read gets no record, and the plan says so.

status and update show the record in the RECORD block:

RECORD      status: My_Old_Campaign: last updated 2026-11-01 14:02 by ck3-save-updater 0.3.17 from My_Old_Campaign.ck3 (1 update)
        pre-filled: --var witness=W1
        pre-filled: --var tools_dir
                    D:/my ck3 tools/a folder whose path is longer than the line
                    (from the record of My_Old_Campaign)

One row per input; a value too long for the line, or a list, goes on its own lines under the value column; the record they came from is named once, after them.

Any input you do not give this time takes the record’s latest value (pre-filled); anything you give wins. A recorded folder or file that no longer exists is not used: the plan says the recorded value was missing, and a step that needs it is skipped with its usual “needs” reason. --no-record (on status and update) neither reads nor writes the record.

Updating in place

update --in-place gives the updated save the original’s name and keeps the original as <name>.bak.ck3:

  1. The output is written to a temporary name in the same folder and verified, as any output is.
  2. The original is renamed to <name>.bak.ck3.
  3. The output is renamed to <name>.ck3.

If the last rename fails, the first is undone: the original keeps its own name, and the run exits 1 naming both files. Only a clean run is put in place: when lint finds an error (exit 4), the original is left as it is and the output is written to <name>__updated__<game version>.ck3 for inspection, with its lint file and report beside it. An existing .bak.ck3 is refused (exit 2) unless you give --force. --no-bak keeps no backup: the original is gone once the update takes its name. backup = false in the config file makes that the default, and --bak keeps one for a single run. The report is <name>.report.json. --in-place does not take -o. A custom faith with no --custom-faith-as gives two outputs, so in place needs --custom-faith-as faith or rite (or one in the record). Without --in-place, the output is still <name>__updated__<game version>.ck3.

Performance after updating a large save

A large updated campaign can stutter in 1.20.1.2 where a new game with the same mods does not. Both causes below were measured on the founding campaign on 2026-10-28. Both are the game’s own 1.20.1.2 behaviour, which a big updated save makes visible, and both have workarounds.

Top-bar alerts checked one at a time

The game re-checks the player’s top-bar alerts one at a time, even while paused. On this save two vanilla alerts each cost about 0.55 seconds per check, and together they froze the game every 2 to 3 seconds:

Portraits recalculated every 30 frames

Portraits on screen are recalculated every 30 frames, paused or not; the number is PORTRAIT_CACHE_EXPIRE_FRAMES in common/defines/jomini/portraits.txt. A character window with a large family keeps dozens of portraits rebuilding, and froze the game for 0.5 to 0.7 seconds in every 5.

Overriding that file in a mod with a value of 600 cut the freezes about tenfold. The mod must override common/defines/jomini/portraits.txt itself: a define file elsewhere in common/defines/ did not take effect (checked by reading the value the running game was using).

A performance mod

A packaged mod with these settings is planned. Until then, the settings change and the small local mods above are the workarounds.

Mods known to misbehave in 1.20

When the game updates again

Doing it by hand

update runs migrate, the lower-level command, with the rules its plan chose. The same flow can be done step by step.

Look at the save. ck3update inspect My_Old_Campaign.ck3 shows the version the save was written by (version, save_game_version, portraits_version), its mods and its size, and the game installs found with their versions. Nothing is written. migrate refuses a save written by a newer game version than the game it uses, naming both versions; when it cannot read the game’s version, it says so and goes on.

See what it needs. ck3update check My_Old_Campaign.ck3 lists every rule (patch) with its verdict on this save: needed (and how many edits, or how many of what the rule fixes), done, unknown (a code or run patch: only running it tells; or a rule whose detector needs the game folder or a reference save), or fails. Nothing is written. Exit code 5 means a patch would fail; the line names it. ck3update rules lists the rules with what each does.

Migrate. The everyday command, with the default rules:

ck3update migrate My_Old_Campaign.ck3 --game-dir "<game folder>" -o My_Old_Campaign__updated.ck3

For a save from before the map rework, add the new-map rules and the two extra folders:

ck3update migrate My_Old_Campaign.ck3 --rules all,R14,R15,R16 ^
    --reference Reference_At_My_Date.ck3 --game-dir "<game folder>" --old-game-dir "<old game folder>" ^
    -o My_Old_Campaign__updated.ck3 --report My_Old_Campaign.report.json

(^ continues a line in cmd.exe; use a backtick in PowerShell and \ in bash.) The report lists every change and why. migrate ends by linting its output.

The update is reproducible: the same save and the same options give the same result every time. A .ck3 file is a zip that records when each file inside it was written, so two runs give files with different bytes but the same content; compare saves by their content (ck3update inspect), not by the files’ bytes.

Choosing rules:

Check the result before loading it. ck3update lint My_Old_Campaign__updated.ck3 --game-dir "<game folder>". Errors are things the game is known to crash or refuse on; warnings are things old campaigns carry and play with. Exit code 4 means an error was found.

Exit codes

Code Meaning
0 done
1 bad input (a missing file, a bad option), or a refused plan
2 refused by a guard (the output exists, or it would overwrite the input)
3 the written file failed its own verification; nothing was written
4 lint found an error
5 a patch failed (migrate writes nothing; check names it)