wakit / Guides

Merge an old WhatsApp database into your current one

An old phone, a WhatsApp mod you switched away from, or an adb backup leaves you with a msgstore.db full of history your current WhatsApp doesn't have. wakit copies it across, chat by chat, and skips everything you already have.

What you need

Steps

Prefer clicking? Run wakit gui (or double-click the app): the same steps are under Guides, with file pickers and Dry run / Apply buttons. Every command is a dry run until you add --apply.

  1. Copy the current database

    $ wakit device pull --out phone/
  2. Check both

    $ wakit doctor --path old/msgstore.db
    $ wakit doctor --path phone/msgstore.db
  3. Dry run, then merge

    --fuzzy also skips messages that reached the current database another way (for example through an imported export) under a different id.

    $ wakit merge --old old/msgstore.db --new phone/msgstore.db --fuzzy
    $ wakit merge --old old/msgstore.db --new phone/msgstore.db --fuzzy --apply
  4. Favourite stickers (optional)

    $ wakit stickers --db phone/stickers.db --from old/stickers.db --from-files old/files/Stickers --files-out Stickers --apply
  5. Put it back

    $ wakit device install --db phone/msgstore.db

What carries over

Messages, media references, replies and quotes, reactions, mentions, links, polls, calls and chat settings. Media files themselves live in the phone's WhatsApp/Media folder, so copy that across too.

Questions

The old database is from a WhatsApp mod (GB, 5Plus…). Does that work?

Usually yes. Mods use WhatsApp's own database layout. Run wakit doctor on it first. If the layout differs, wakit refuses to write and tells you exactly which tables or columns are missing.

Why does sort order matter?

WhatsApp gives each new message a sort position equal to its row id. Merged history has to fit under that, or new messages would appear in the middle of old chats. wakit renumbers everything in time order after each merge.

Other guides