It would be great if you could export backups from Signal Desktop in the same way you can export them from Signal for Android. I've just lost a huge amount of conversations and private keys because of WhisperSystems/Signal-Android#4577, and I'd like to at least partially restore my data from my desktop install.
Would really like this too. My phone died, meaning all my messages will be lost even though I can see them in Signal Desktop still...
Yeah, this would really be a life saver.
I have systematic backups of my messages in Facebook, jabber, ICQ, Telegram. A good backup of my signal messages (including pictures) is direly needed!
@nomeata please don't bump issues.
Besides, you can already backup Signal messages from mobile. At least, you can in the Android app. It doesn't include pictures but I believe someone's working on that too.
Actually, this depends on your use case for signal desktop. If you swap phones often (different SIMs for different countries), then your phone is the only source of truth for your message history, as signal desktop blows away your history every time you re-register a device. Being able to make a backup and restore from the desktop client would mitigate that when you return from travel. I would find it really useful, as I found it surprising the desktop deleted my history the first time I did that.
The reality is mobile devices are lost, stolen, break etc. far more often than desktop computers which means messages will be lost, but remain on the desktop version. Not being able to export/backup from Signal Desktop means it's impossible to get them back in the mobile version.
Aside from exporting and being able to merge backups from the mobile/desktop versions, a way around this would be an option to auto-backup the encrypted message database to a cloud account or send to an email account. That way messages can be recovered when a device is lost etc.
This is my point exactly. I lose and change devices constantly, and would like to have a canonical source of truth of messaging, which lives on my desktop. In the current case, I can't have that without backing up my device regularly and then syncing to a cloud service somewhere and using that as my history. I think we're in agreement here.
How can I help?
I have started implementing a feature for the Desktop client that would create a zip file consisting of all messages of (for now one) conversation, together with all media files. Let’s see how far I get (tomorrow).
I noticed that this is issue more about an data export (that can be imported) than a archive export (which is meant to be readable independent of Signal), so I created a separate issue for that at #1013.
In issue #1017 it is mentioned that Signal Desktop stores unencrypted messages locally. Is this true? Does anyone know where these messages are stored?
My situation is as described by @ThoughtPhotography, my phone broke irreparably and I wasn't able to backup my conversations. I still have my Desktop client, with all the history. I would like to be able to download and save all my messages before I try installing signal on my new phone and linking desktop. It looks as though I'll have to uninstall/reinstall desktop to sync new phone's Signal, and I doubt my history will carry over.
@jessebett you don't have to reinstall. You can relink Signal Desktop in its settings and your history will stay.
@strugee I don't want to stray too far from the thread issue, but can I relink in Desktop if I wasn't able to unlink first from Mobile? I don't see any option for that in my Desktop settings.
@jessebett yes, you can.
In issue #1017 it is mentioned that Signal Desktop stores unencrypted messages locally. Is this true? >Does anyone know where these messages are stored?
Stored unencryptedly in Chrome’s IndexdDB.
I worked some more on the export. The export-to-zip worked nicely, until my history became too large. Maybe some kind of 100MB problem, maybe a bug in zip.js.
So I refactored the code and it now supports either exporting a zip file (with the chat history and all media), or simply to an empty directory.
The code is, in “works for me state” at the GitHub clone at https://github.com/nomeata/Signal-Desktop/. I am still willing to clean this up into a mergable state, if the feature itself is deemed desirable.
Why do you need to reinstall?
Well, how do I switch from the official version to yours?
I go to $HOME/.config/google-chrome/Default/Extensions/idof theapp/0.42.6_0 and apply the patch, as produce by git diff, using patch, and then restart the browser. It does not quite apply the translations properly, to the button to do the backup is unlabeled, but otherwise it works for me.
(I only recommend following this if you know git, patch and chrome apps in general well enough to understand the above procedure. And backup everything first properly, of course.)
The “migration to signal-desktop” offered by the Chrome app does precisely what I need. Can we get that functionality also in the new stand-alone app?
@nomeata Would love to know a little bit more about your scenario. The current export functionality copies the entire app, including all encryption information. It's dangerous, because if you export, then continue using the original app as well as the new, copied app, you'll run into lots of errors.
The scenario is archival. I want to get all data out in a format that I can, hopefully, read in 20 years even without the Signal software around. Maybe “backup” is the wrong word, as I do not want to restore it into Signal.
Ah, as expected: The backup functionality is present in the the new stand-alone program, just not exposed via the UI. But Ctrl-Shift-I and
Whisper.Backup.exportToDirectory("/tmp")
does precisely what I need.
This is good enough for me, and if the Signal devs have good reasons not to expose that functionality in the UI, then I will not argue and happily use the developer console for my backups.
Tip: Run
for file in /path/to/the/backup/**/*.json ; do json_pp < "$file" | sponge "$file"; done
for prettier json files and (if you keep the backups in a git repo) better diffs.
@nomeata Thanks! This is really useful, e.g. in case the conversation needs to be archived or be made available to other parties.
Alright, you're getting fancy. :0) I would recommend that you delete the root-level db.json, since it has sensitive encryption data in it. Also, you should know that the conversation directory names start with a timestamp representing the last activity of that contact - so your git diffs will be pretty substantial.
Thanks for the heads-up! The latter can be fixed with
rename 's/^.* \((.*)\)/$1/' *
On my Debian GNU/Linux system, I got this when I ran that rename command:
find: warning: Unix filenames usually don't contain slashes (though pathnames do). That means that '-name `*.s/^.* \\((.*)\\)/$1/'' will probably evaluate to false all the time on this system. You might find the '-wholename' test more useful, or perhaps '-samefile'. Alternatively, if you are using GNU grep, you could use 'find ... -print0 | grep -FzZ `*.s/^.* \\((.*)\\)/$1/''.
Files successfully renamed!
Despite the last line, the files weren't renamed. I couldn't figure out how to fix the rename command, so I did this instead:
ls | while read file; do new=$(echo $file | sed -e 's/^.* (\(.*\))$/\1/'); mv "$file" "$new"; done
and that worked.
There is great news on the front of backups/restore on Android in https://github.com/signalapp/Signal-Android/pull/7380
@roghetti would you please consider also spinning a PR for the desktop version here? It would solve the problem of backups here and allow for restoring between ones PC-Android (ideally, if the PR can be changed to as much platform agnostic as possible- which it quite seems, only the GUI parts are "android-only"- the we could have all Android/iOS/PC backup&restore)
@nomeata are you able to import this into the mobile app to restore conversations?
Sorry, I did not try, since that is not my use-case.
are you able to import this into the mobile app to restore conversations?
Could someone test it, please? I'd also be interested in the other way: backup on mobile, import on desktop.
Is there a "hack" to allow us to export anomore?
The method described in https://github.com/signalapp/Signal-Desktop/issues/522#issuecomment-352632969 no longer works (neither the updated call, as the procedure now requires a key).
I'll be switching notebooks soon, and I wish to move to the snap version of the package, what is the way to cope with that, please? I definitely don't want to lose track of all my conversations.
Signal is great, but this import/export needs more work, with signal I always feel this "vendor lock-in" with regards to data and clients.
found a way to create/migrate signal-desktop backups:
cp -a .config/Signal/ .pki/ ~/signal-desktop_backup-2018-05-15Not sure how the backup/recovery works between different signal version (format incompatibility),
but for the app/snap and device-to-device desktop migration it works and was tested.
Note: no need to link a new device with the mobile, as this copy essentialy acts as the prev. linked
device.
Posting here, as there is no wiki and I don't frequent the forums here.
@breznak Yep, that works in a pinch. Certainly you'll have your old messages. But you'll likely need to 'Reset Session' a couple conversations to get back into a good state. As has been discussed previously, the Signal Protocol is stateful. You'll run into difficulties if messages have been exchanged in a given conversation since that backup was taken.
Another thing to watch for: be sure to have Signal Desktop closed when you copy its data into a backup directory.
@iflowfor8hours You said mobile phone is the only source. My experience is exactly the opposite. My phone got broke so I switched a few phones. My full history is still in the computer, no way to sync it back to the fixed phone (went through a fresh system install) now.
Does anyone know how to copy messages from Signal Desktop on Mac? I've just gotten a new phone and I'd love it if the old messages on my desktop weren't gone forever.
@chrisguida If you still have the old phone, you can unregister desktop and then link it to the new device without losing any history. If you can't unregister the old device, you should still see the 'Relink' prompt if you restart Signal Desktop after setting up the new phone with your same phone number. Either way, you'll still have your old messages if the phone number is the same.
I don't have the old phone anymore, I was dumb and did a factory reset at the store while trading it in for the new one. So you're saying that I can relink Signal Desktop to my phone and it won't delete all the old messages from Signal Desktop? Will it also copy the old messages back to my phone? Because that would be amazing.
Will it also copy the old messages back to my phone? Because that would be amazing.
I'm genuinely interested too. Will be switching phones, keeping desktop messages would be great, keeping also phone's whould be best!
@breznak You can use the built-in backup functionality of signal-android when switching phones. Desktops don't lose messages during this transition.
@tribut thanks for mentioning that! Unfortunately, I'm switching to iOS and there's no Import feature there, yet, or ever :/
@breznak, @chrisguida: Unfortunately, right now old messages are never copied between devices. There's a feature request for this though: #2533
Hi, Any updates on this?
There are some export workarounds available here: https://github.com/signalapp/Signal-Desktop/issues/2516
I think this would be a killer feature for Signal - I lost my phone recently, but still have two instances of Signal Desktop running. They work fine and I can continue using Signal even without my phone (which is such an unexpectedly good feature!), but now I would like to sync the messages and groups from Desktop back to my new phone. Instead, my only option is to completely reset Signal Desktop and lose all existing messages/chats.
It would be great to be able to sync (or export/import) from any existing Signal application to any other - that you could piece together your past groups and messages, even from different sources/backups, at least if it is the same number/account. Because with two Signal Desktop instances running, I will never lose both of those, but my phone might get lost, broken or stolen easily.
Bump and cosign the above requests for this as a top tier feature. I'm technical enough to dig messages out manually, but it would be great to have this as a well-supported export option. If that's something I can help with, please point me in the right direction! :smile:
Yeah, same situation here. I would love this feature!
I tried the approach from https://github.com/signalapp/Signal-Desktop/issues/522#issuecomment-352632969 just now with window.Signal.Backup.exportToDirectory("/Users/user/tmp") but get
Uncaught (in promise) Error: export is only supported in test mode
at Object.exportToDirectory (/Applications/Signal.app/Contents/Resources/app.asar/js/modules/backup.js:1215)
at <anonymous>:1:22
which worked earlier this year. I could not find information on the mentioned "test mode". Any ideas? @nomeata?
I looked at the source and tried this
window.getEnvironment = function(){ return "test" }
which works around that test mode check.
Now I tried to export, but got
Uncaught (in promise) Error: Encrypted backup requires a key to encrypt with!
at Object.exportToDirectory (/Applications/Signal.app/Contents/Resources/app.asar/js/modules/backup.js:1221)
at <anonymous>:1:15
after which I tried the approach in https://github.com/signalapp/Signal-Desktop/issues/1013#issuecomment-397571288 which fails, see https://github.com/signalapp/Signal-Desktop/issues/1013#issuecomment-568268657.
Hi, Any progress, working solution for this ? keen to get my old signal on my new laptop, vs running a vm just to keep it going
I can see a 'setup from import' in desktop client, but cannot see the export feature it mentions i need to use
Thx
@zippytiff If you're moving from one computer to another, you can shut down Signal Desktop, move its data directory to the new computer and Signal Desktop should start up fine on the new computer using that data.
Hi
Thanks
Do you mean the contents of
AppData\Roaming\Signal
Thx
ZT
From: Scott Nonnenberg [[email protected]]
Sent: 13 January 2020 19:09
To: signalapp/Signal-Desktop
Cc: Tim Middleton; Mention
Subject: Re: [signalapp/Signal-Desktop] Allow exporting a backup from Signal Desktop (#522)
@zippytiffhttps://github.com/zippytiff If you're moving from one computer to another, you can shut down Signal Desktop, move its data directory to the new computer and Signal Desktop should start up fine on the new computer using that data.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/signalapp/Signal-Desktop/issues/522?email_source=notifications&email_token=AHQVIR2ENT7E3S2TMMQGQGDQ5S363A5CNFSM4BW3YT72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEIZ5E3A#issuecomment-573821548, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AHQVIR2JW44E7CYFKWAV7ELQ5S363ANCNFSM4BW3YT7Q.
@zippytiff Yup, that's correct!
Perfect, that’s worked a treat !
ZT
On 14 Jan 2020, at 18:04, Scott Nonnenberg notifications@github.com wrote:

@zippytiffhttps://github.com/zippytiff Yup, that's correct!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/signalapp/Signal-Desktop/issues/522?email_source=notifications&email_token=AHQVIR4NCRJ6ZUCEMQ7QIWDQ5X4TTA5CNFSM4BW3YT72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEI5RTPQ#issuecomment-574298558, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AHQVIR4DL3VUM4E4GRCZE6TQ5X4TTANCNFSM4BW3YT7Q.
@scottnonnenberg-signal Is there any way to export a Signal desktop backup and then import it on Signal Android?
I'm trying to get years of message history from my desktop (where it still exists) to my phone (where I lost all history)
I've been searching the internet for hours but haven't found a definitive answer to that question. This was the top result for most of my searches, so your answer will help countless others.
@DanDoes There is no way to do that today, no. If you wanted to do it yourself, you'd need to become a true expert on both Desktop's data formats and Android's data formats to write the translation tool.
@scottnonnenberg-signal Dang. Thank you for the answer.
For laymen users like me, is there a place we can show our support for that future feature?
(Upvoting #2533 seemed right, but it seems upvotes cannot be cast while the request is locked?)
The forums are always a good place to express your desires for Signal, and even connect with like-minded folks over those desires: https://community.signalusers.org/
@scottnonnenberg-signal Honest question, why is this GitHub issue not indication enough to gauge interest? I mean it's not like its uncommon to file an issue over a feature request on this site... :)
@NiklasBr We definitely pay attention to these issues. In the long term, however, Desktop will follow the lead of the iOS and Android repositories, and stop tracking feature requests on GitHub.
In other words, post "Allow restoring from Signal Desktop" in the Signal-Android repo?
No, but this issue is a prerequisite for that. Way back when this issue was filed, those made more sense as the same step, because Signal Android had a much simpler, much less Signal-Android-specific backup format. But that's no longer true, so Signal Desktop would probably end up having a significantly different export format.
I would also love this feature. And my use case is that I would like to to be able to backup individual user conversations, mostly for long term archival & backup purposes but also to be able to easily revisit important conversations easily on my WIndows desktop, independently of my phone status. Plus, there might be a future where I'm not using Signal anymore... (horrible thought! :) but I'd love to see what was said.
Having this backup feature in Signal would make me want to transition away totally from iMessage on iPhone, as there is not such backup feature for that messaging platform.
Keep up the great work!
@cloudgreen I think iMessages can be backuped to iCloud, it requires 2FA to be set up though.
Anyway sorry to everyone else for the "noise" as that's unrelated.
Better backup/sync functionality in Signal would definitely be highly appreciated on my end, as it happens quite a lot that you set up a new desktop/laptop computer (e.g. buying a new one, formatting etc) or a new mobile device, and it would be great to have all history available on all devices, even on the newly setup ones.
@patrikhuber Thanks! I do use the iCloud backup, but consider it to be for "Apple ecosystem purposes only", if you know what I mean. You can't access it, export it, view it or do anything else with it really... except restore it. :)
A data backup / data export feature for Signal is something I want out of a data portability perspective. To get the data out of the device, for "posterity", for archival in a format that is readable on all platforms. But obviously also for purposes of migration to a new device, as mentioned previously in the discussion. I hate the feeling of my data being "locked in". :)
Hello,
I am absolutely new to github and I hope I can find help here. Ich habe an iPhone with the Signal messenger on it and starting this morning I cannot open the app anymore. There is alays the notice, that the app needs to be purchased again from the app store. I think I could delete and reinstall the app, but then all my conversations would be lost. I am also using the desktop app on my Mac (MacOS 10.15.4) app version 1.34.1. In the desktop app all conversations (also new massages) are there. I want to make a backup of these messages before I delete the app on the iPhone. It would be cool, if I could restore the messages. But this is not a must. I think this thread is the correct one, but I do not understand how I can do that.
Can anyone please help?
Relinking the desktop app does not delete existing messages, so you don't need to make a backup beforehand. However there is not currently a backup and restore mechanism in the iOS app.
Hello strugee,
thanks for the reply. But the desktop app is not the issue. The original installation on the phone is the issue. I am quite sure, when I delete the app on the phone and reinstall it my conversation will be gone. They will probably also be gone in the desktop app. That's why I try to get an export from the desktop app, where all the conversations are still there. Or do you think that the conversations from the desktop app will be transferred to the phone app. I don't think so.
@MUG222 I also believe you will lose all messages if you delete the app on your phone.
The Signal Desktop app really needs an "Export discussion as HTML/XML" option. That would be fabulous!
Yes, everything is gone on the phone (as expected) but I still have the data on the MacBook. I am still working to get the export done. On the other hand I can just keep the data on the computer. But an implemented export function would be awesome!
@MUG222 please reread my reply - I addressed all of your questions there. Specifically this:
They will probably also be gone in the desktop app.
is incorrect, as you've noticed. But again, as I've mentioned, even if the desktop version had an export feature there would be no way to import that back into the iOS app. (And no, there is nothing implemented to transfer conversations from the desktop app to the iOS or Android apps.)
@zippytiff If you're moving from one computer to another, you can shut down Signal Desktop, move its data directory to the new computer and Signal Desktop should start up fine on the new computer using that data.
@scottnonnenberg-signal Is this still possible from the windows desktop app? The Github page on this makes it sound like it's not. I need to reinstall windows and then the signal app and I'd like to take my message history with me.
@Jayman007 what exactly makes it sound like it's not possible? I don't see why it wouldn't be.
@Jayman007 what exactly makes it sound like it's not possible? I don't see why it wouldn't be.
I guess it would be this...
"Manually transferring folders is not supported and may result in errors. Signal uses a stateful protocol, meaning that you cannot simply copy files to another instance of Signal or copy files after linking and using Signal."
That said, it totally worked for me. :)
Why not implement a import feature of android-backups?
In my opinion this is a problem and if signal find no way to fixed this, there will be more projects like this:
https://github.com/mattsta/signal-backup
This software is not workig: https://github.com/mattsta/signal-backup/issues/13
Any other ideas what to use?
This software is not workig: mattsta/signal-backup#13
Any other ideas what to use?
https://github.com/bepaald/signalbackup-tools works best currently.
Well, as I said, I am looking for Signal DESKTOP backup tool.
I've only just started using Signal after experiencing issues with Element, and the fact that this isn't a feature is disappointing. It seems to be worryingly easy to lose your messages on both platforms. Whilst lots of people apparently delete their messages, some of us think it's nice to be able to search through previous messages - e.g. to remind yourself of what has been said, facts about another person you've forgotten, look at old photos, etc.
I understand this isn't necessarily a priority feature, but I'm very surprised this issue hasn't been resolved after 5 years. If backups are allowed in Android, then they should be supported on desktop as well. Losing entire chats isn't a feature for people who use Signal as an alternative to services like Discord. Not everybody wants their messages to be erased.
I understand this isn't necessarily a priority feature, but I'm very surprised this issue hasn't been resolved after 5 years. If backups are allowed in Android, then they should be supported on desktop as well. Losing entire chats isn't a feature for people who use Signal as an alternative to services like Discord. Not everybody wants their messages to be erased.
Exactly. And for those of us on iOS it's extra important, since Signal backups are not possible at all on iOS. (Since it's available on Android, it shouldn't be a security issue that prevents this from being implemented?)
But I would be happy with just being able to export full conversations on Signal Desktop to HTML or XML...
Just lost another 6 months of conversation history thanks to the lack of this feature.
phone has just not enough space for me to be able to export backups there
Just lost another 6 months of conversation history thanks to the lack of this feature.
Me too. Again :(
For those not subscribed to #2516 / #1013, the current best way to export data from Signal (since ~2018) is with sqlcipher:
sqlcipher ~/.config/Signal/sql/db.sqlite \
"PRAGMA key = \"x'$(jq -r '.key' ~/.config/Signal/config.json)'\"; attach database 'plaintext.db' as plaintext key ''; SELECT sqlcipher_export('plaintext'); DETACH DATABASE plaintext;"
The resulting plaintext.db will be a normal, unencrypted SQLite database file. This requires SQLCipher 4, and the above example also requires jq, though you could also copy/paste the encryption key instead.
Attachments can be directly copied from ~/.config/Signal/attachments.noindex/*.
It's a real shame there isn't a fix for this. Had to wipe my device had all my data synced to the signal desktop app and now I can't retrieve it back to my phone. Will the two be in sync though? If I reinstall it on my phone will the messages be added to my desktop app?
Note that if easy multi-device access to your messaging content is important to you, there are alternative architectures and apps.
This syncing issue is the main reason I prefer to use Keybase instead. They provide an elegant solution.
Is there a good solution, one that doesn't involve trusting servers with private keys? At Keybase, we think yes: true multi-device support. This means that you control a chain of devices, which are you. When you get a new device (a phone, a laptop, a desktop, an iPad, etc.), it generates its own key pair, and your previous device signs it in. If you lose a device, you "remove" it from one of your remaining devices.
See the details at https://keybase.io/blog/chat-apps-softer-than-tofu
Note that there are inevitably issues with Keybase also, and with its approach. But it can be helpful to consider well-thought-out alternatives.
@ParisKellySkopelitis no it will not. I had hoped I could do that. The link between the desktop and mobile versions is broken so Signal desktop will ask you to fix it; you follow the steps and the desktop version (apparently) clears the history. I haven't looked at what it was actually doing (so the data might still be there somewhere), I just accepted the (for me) minimal loss.
@jcuenod Okay thanks.
Would be interesting if there was a tool that could convert SCAB style backups (https://github.com/mattsta/signal-backup) to signal mobile backups
Note that if easy multi-device access to your messaging content is important to you, there are alternative architectures and apps.
This syncing issue is the main reason I prefer to use Keybase instead. They provide an elegant solution.Is there a good solution, one that doesn't involve trusting servers with private keys? At Keybase, we think yes: true multi-device support. This means that you control a chain of devices, which are you. When you get a new device (a phone, a laptop, a desktop, an iPad, etc.), it generates its own key pair, and your previous device signs it in. If you lose a device, you "remove" it from one of your remaining devices.
See the details at https://keybase.io/blog/chat-apps-softer-than-tofu
Note that there are inevitably issues with Keybase also, and with its approach. But it can be helpful to consider well-thought-out alternatives.
The problem is that there really aren't any all around good chat apps. They're all lacking in one way or another. You either sacrifice privacy or useability and features.
Whatsapp is owned by Facebook, Discord works well but will never support end-to-end encryption, Wickr is closed source, Telegram isn't end-to-end encrypted by default and uses a weird protocol, Keybase got acquired by Zoom, Element is consistently buggy, and Signal requires a phone number and you lose all of your messages when you want to change devices.
There are some other services, but most of them are in beta and not well known compared to the ones I've listed above. Then there are peer-to-peer messengers, but those aren't suitable for most people.
Lets hope the increase in Signal users will lead to improvements like supporting backups. It would be great to see them finally resolve the phone requirement as well. It seems rather silly having a privacy respecting service that requires the user to have a phone and share their phone number.
@MatejKovacic wrote:
This software is not workig: mattsta/signal-backup#13
This fork-of-an-offspring project carderne/signal-export works fine in --manual mode.
can confirm that carderne/signal-export works fine in --manual mode for me
Most helpful comment
Would really like this too. My phone died, meaning all my messages will be lost even though I can see them in Signal Desktop still...