[GUIDE] How to restore / import Line chat history!

Search This thread

xAxB

Senior Member
Mar 9, 2017
59
13
Guess it's worth to skip-read back in forum posts once in a while as fast forward to June 2022, this did it for me, so you shall be my saviour!

After spending about two days with this piece of crap software what Line technically is (unfortunately extremely widespread and popular in Asia and especially in Japan) with force close here and splash screen doodling there despite copying myself clumsy and stiching obscure SQL-databases together, finally the braindead patient could be sucessfully reanimated.

Uargh, I really wonder what kind of retarded developers at "Naver" are responsible for this mess. Not only are they apparently still incapable of providing a decent backup function (which one would actually expect to be provided system-wide by Android itself to be fair, however Google isn't much better here), but they also make it especially difficult and painful to backup anything beyond a few recent chats in the first place. That in conjunction with tenshousands of distributed files in even more subfolders after some years of usage which one can manually copy and shift around, totally insane.

I wish the Line developer team to lose their phones, all their content while being in urgent need to lookup some chat or images from the past. Maybe then they may get a glimse of how ****ty and moronic it is.

Alas, they might be using the iPhone version of the app. My iPhone using friends mentioned they can backup everything, photos and all. Not sure if it is because the iOS do backup better (TBF, I think they do, LINE isn't the only app where Google's backup is half-assed), or Naver did a better job with the iOS version.

One thing I wonder is how are chat saved on their server and for how long. I noticed some "interesting" behaviour recently. Basically, if you manage to restore LINE on a new phone, it is sort of possible to run LINE on two devices. LINE sometime detects it and will try to wipe one of the phone, but you can usually force close and void that from happening. You can also avoid this from happening by not having both phone switched on at the same time. Any recent messages will also be received on the backup phone once you switch it on. I used to take that as evidence that LINE basically store everything anyway, but it seems like that is not the case.

Recently my main phone suddenly died without warning. At that point in time I hadn't switched on my backup phone for a while, and left it in a different city. Several months later, when I finally got hold of my backup phone and switched it on, LINE was still working, but 1. Messages from my main phone received after I switched off the backup phone are forever lost, LINE did not bother pushing those messages to the old devices. However, those messages can still be viewed on the PC version which I used in conjunction of the main phone when it was still working. 2. A number of messages sent between the time my main phone died and switched on my backup phone were also forever lost somewhere. LINE won't deliver messages that are several months old if if you don't log into LINE either via phone or PC within a time period (if your device is off for a few days that is fine, but a few months is NG - I am not sure what the cut off time is). This behaviour is quite different from other chat I have used.

What this means is that while I can keep LINE installed on older devices to keep as backup in case something happens to my main device, if I don't periodically switch it on to allow the backup devices to receive recent messages within a timeframe, the backup will be incomplete.

(Not sure if this information will be of any use to anyone, but lesson here is to either periodically switch on the backup device or regularly backup your LINE if you don't want to lose anything if something happens)
 

Pcsl

Member
Jul 14, 2010
27
8
Hello there!

As per my usual routine, whenever I find myself doing a full wipe on my Android device, I always make sure to come back here and consult the steps and recommendations shared to avoid those annoying limitations when it comes to restoring the LINE app without a proper backup system. Seriously, it's quite frustrating how they make it so complicated!

But hey, I've got some great news to share with you. In the past, I used to rely on the outdated Titanium Backup, but it's difficult to make it work for most of the apps nowadays so I switched to this app called Swift Backup. And the good news is, with the proper configuration, Swift Backup seems to be capable of restoring LINE as well.

How to do it? It appears that if you check the box labeled "Restore app SSAIDs" in Swift Backup, LINE opens up without any additional hassle. This nifty feature restores the app's original ID. Although I personally believe it may not be necessary, just to be on the safe side, I recommend activating this option when creating the backup, not just during the restoration process. Oh, and one more thing, after restoring LINE, it's essential to restart your device; otherwise, you might encounter some troublesome issues.

Initially, when I tapped on the LINE icon, nothing happened. You know, that all-too-familiar symptom where the app detects that you're using a different device. Even after restarting, the app still refused to open. However, I stumbled upon a little trick that did the trick for me: I uninstalled the app and then restored it again. Voilà! That did the trick, and I was able to use LINE without any additional fuss. Hence, I wholeheartedly recommend considering Swift Backup for your backup needs. While there may be other apps out there with similar functionalities, I haven't come across them just yet. If you happen to know any, I'd be delighted to hear your recommendations. All I can say is that Swift Backup works like a charm and can save you from the laborious steps that this amazing community has managed to decipher. Of course, if a direct restoration method exists, all the better!

To sum it up, here's a quick rundown of the steps to restore LINE, as I mentioned based on my personal experience:

  1. Opt for Swift Backup or other backup app with SSAID restoring capabilities
  2. When you restore LINE using Swift Backup, make sure to turn on the "Restore app SSAIDs" option. I think It's not required, but it's a good idea to enable this option when you're creating the backup, not just when you're restoring it.
  3. Once the restoration is complete, it's crucial to restart your device. Trust me, this step is vital; otherwise, LINE may not open.
  4. After restarting your device just opening the LINE app should do the trick and you could continue using LINE in your new device (actually I think that probably could let you keep using LINE in 2 different devices)
  5. If the LINE app still won't open uninstall the app and restore the backup once again (actually most of the time I had to uninstall before I could make it work).

Please bear in mind that these steps might vary depending on the specific device and software versions you're using. If you happen to stumble upon any additional tips or alternative methods, feel free to share them with the wonderful folks in this forum.

I sincerely hope this information assists you in restoring LINE after a full wipe without causing you unnecessary stress.
Best of luck!
 
Last edited:
  • Like
Reactions: _raydroid and Ghisy

_raydroid

Senior Member
Feb 7, 2017
94
33
Hello there!

As per my usual routine, whenever I find myself doing a full wipe on my Android device, I always make sure to come back here and consult the steps and recommendations shared to avoid those annoying limitations when it comes to restoring the LINE app without a proper backup system. Seriously, it's quite frustrating how they make it so complicated!

But hey, I've got some great news to share with you. In the past, I used to rely on the outdated Titanium Backup, but it's difficult to make it work for most of the apps nowadays so I switched to this app called Swift Backup. And the good news is, with the proper configuration, Swift Backup seems to be capable of restoring LINE as well.

How to do it? It appears that if you check the box labeled "Restore app SSAIDs" in Swift Backup, LINE opens up without any additional hassle. This nifty feature restores the app's original ID. Although I personally believe it may not be necessary, just to be on the safe side, I recommend activating this option when creating the backup, not just during the restoration process. Oh, and one more thing, after restoring LINE, it's essential to restart your device; otherwise, you might encounter some troublesome issues.

Initially, when I tapped on the LINE icon, nothing happened. You know, that all-too-familiar symptom where the app detects that you're using a different device. Even after restarting, the app still refused to open. However, I stumbled upon a little trick that did the trick for me: I uninstalled the app and then restored it again. Voilà! That did the trick, and I was able to use LINE without any additional fuss. Hence, I wholeheartedly recommend considering Swift Backup for your backup needs. While there may be other apps out there with similar functionalities, I haven't come across them just yet. If you happen to know any, I'd be delighted to hear your recommendations. All I can say is that Swift Backup works like a charm and can save you from the laborious steps that this amazing community has managed to decipher. Of course, if a direct restoration method exists, all the better!

To sum it up, here's a quick rundown of the steps to restore LINE, as I mentioned based on my personal experience:

  1. Opt for Swift Backup or other backup app with SSAID restoring capabilities
  2. When you restore LINE using Swift Backup, make sure to turn on the "Restore app SSAIDs" option. I think It's not required, but it's a good idea to enable this option when you're creating the backup, not just when you're restoring it.
  3. Once the restoration is complete, it's crucial to restart your device. Trust me, this step is vital; otherwise, LINE may not open.
  4. After restarting your device just opening the LINE app should do the trick and you could continue using LINE in your new device (actually I think that probably could let you keep using LINE in 2 different devices)
  5. If the LINE app still won't open uninstall the app and restore the backup once again (actually most of the time I had to uninstall before I could make it work).

Please bear in mind that these steps might vary depending on the specific device and software versions you're using. If you happen to stumble upon any additional tips or alternative methods, feel free to share them with the wonderful folks in this forum.

I sincerely hope this information assists you in restoring LINE after a full wipe without causing you unnecessary stress.
Best of luck!
Thanks for this guide, Pcsl. Would your Swift Backup guide work for non-rooted devices or if you use something like Shizuku with Swift Backup?
 

Pcsl

Member
Jul 14, 2010
27
8
Thanks for this guide, Pcsl. Would your Swift Backup guide work for non-rooted devices or if you use something like Shizuku with Swift Backup?
Unfortunately it seems that even Shizuku is not enough. Root is required according to Swift Backup FAQ

Data
The private app data in /data/data/ or /data/user/*/ that stores your app preferences, login info, databases, etc. This is the most important part to restore apps potentially with their state preserved.

Requirements:
⚠️ Root required for backup & restore
⚠️ Shizuku mode (ADB access) cannot read/write at these path
 
  • Like
Reactions: _raydroid

Top Liked Posts

  • There are no posts matching your filters.
  • 23
    Skip to How to Import Chat History below to skip the background reading.

    Yes, there is a graphical import method for Line!

    If you use Line, and you want to change between devices, it seems as though it is nearly impossible to backup (export) and restore (import) your Line chat history. I have searched XDA, Google, AndroidForums, Line's (useless) online help, etc. No help, no info. There are some guides about how to use a SQL editor to fool the app, etc., but that was just way too much effort for me, so I finally gave up and just switched. BUT, before I did, I went ahead and exported all my chats, even knowing there was no way to import them, just in case. Well, that just paid off.

    There is absolutely no method available within Line to restore your chat history, right?! WHY is there a backup option? There MUST be a way! Seemingly no.

    I just figured it out. And when I explain it, you too will wonder, why in the !#$%@^$@%!#@$!#$@^*%^&(*%^@# has Naver not published this?????

    I was on my way to back everything up in preparation for a new ROM and figured I'd do a complete and total system wipe, meaning, I went to take a look at my internal storage (SDcard, Emulated, 0, whatever you refer to it as), to ensure that I got all the little things I want, like Viber pictures, WhatsApp pics, etc. And there I saw it. The folder. And, like you are now thinking, I thought, just maybe...

    How to Import Chat History (Abbreviated, Quick and Easy)

    Copy your chatHistory.zip file to internal storage sdcard/LINE_Backup
    Start Line, open an existing chat or start a new chat with the person whose chat history you want to restore
    Tap the drop-down arrow in the upper right, Chat Settings, and look what just showed up below the (formerly) useless Backup Chat History option

    How to Backup and Restore Chat History (Additional Details)

    Line offers a "Backup Chat History" option, but keep in mind, this is conversation / per-person specific. That means, you need to do it for each individual person.

    For my own ease of use, and to make transferring things easy, now that I know what the process is, here's what I did.

    Backing Up

    Go into the conversation you want to backup.
    Tap the drop-down arrow in the upper right, and select Chat Settings.
    Select Backup Chat History, Backup All
    Say Yes to e-mail this chat - in a previous version, I had to enter the conversation person's name in the subject, the new Line now does this for me.
    Repeat this process for every conversation you want to migrate to a new device.

    Restoring

    On your new device, save the attachments from each e-mail into the /InternalSDCard/LINE_Backup/ directory.
    Start Line, go to Chats, Tap the Chat Bubble in the upper right to start a new conversation, select the person you want to restore
    Your chat window will be empty, but from here, you just follow the instructions above, basically, drop-down arrow, Chat Settings, Import Chat History

    And that's it.

    I REALLY hope this helps some people out. I wasted a LOT of time trying to figure this out, and as usual, once you know the solution, it's pretty simple and seems so obvious.

    If I helped, throw me some Thanks button so I know I wasn't the only one!
    19
    I just found a method for importing the chat history using Titanium Backup and the terminal. You need root for this. Recently Line made some changes that made this more
    Hope you find this useful.

    1. Restore Line with Titanium Backup (app+data) (DON'T OPEN THE LINE APP YET!)

    2. Log into a root shell and delete the previous settings:

    sqlite3 /data/data/jp.naver.line.android/databases/naver_line
    delete from setting;
    .quit


    3. Now we have to delete this xml only if you are using a recent version. In previous ones it didn't even exist as far as I know
    rm /data/data/jp.naver.line.android/jp.naver.line.android.settings.xml

    4. Open the Line app and it will ask you to enter your user and password.
    You will receive a warning about losing your chat history. Just ignore it and...

    5. Enjoy!
    10
    This gives me this error:
    Error: unable to open database "data/data/jp.naver.line.android/databases/naver_line": unable to open database file
    I use the emulator in ROM Toolbox Lite
    Got it! I was missing the su command to make the emulator rooted.
    I also found the jp.naver.line.android.settings.xml file in a slightly different location than where daimyorl said above (but the credits go to him). For me it was into /data/data/jp.naver.line.android/shared_prefs/

    Then, the complete instructions that worked for me are:

    1. Restore Line with Titanium Backup (app+data) (DON'T OPEN THE LINE APP YET!)
    2. Log into a shell and delete the settings:
      Code:
      su
      sqlite3 /data/data/jp.naver.line.android/databases/naver_line
      delete from setting;
      .quit
    3. Remove jp.naver.line.android.settings.xml
      Code:
      rm /data/data/jp.naver.line.android/shared_prefs/jp.naver.line.android.settings.xml
    4. Open the Line app and it will ask you to enter your user and password. It will also ask your phone number for the confirmation SMS.
    5. Enjoy!
    3
    Just my 2c... This method if backup/restore sucks... not because of the OP, but because LINE doesn't have a batch backup/restore option!!! Have hundreds of conversations that I'd like to maintain... which means, hundreds of times of clicking backup etc etc, the hundreds of times clicking restore etc etc.

    FYI, if you are willing to root your phone and pay for TIBackup Pro you can simplify the process. Backup LINE (user apps) and your SETTINGS (system apps) with TIBackup. Copy TIBackup folder to external sdcard or PC. Do whatever you were going to do that required you to backup/restore LINE. Load up TIBackup, load up the TIBackup folder, restore LINE APP+DATA, then goto the menu in TIBackup and scroll to the bottom and select 'manage android id' and select restore from backup (if you backed up the correct settings data under system data there will only be ONE option). Your phone will automatically reboot. Click on LINE, boom everything just like it was before.
    2
    Xml to be removed

    My line version is 6.2.1

    And the xml to be removed is android_preferences. xml
    Code


    su
    sqlite3 /data/data/jp.naver.line.android/databases/naver_line
    delete from setting;
    .quit


    rm /data/data/jp.naver.line.android/shared_prefs/jp.naver.line.android_preferences.xml

    And I successfully restored all the chattings.

    Added note 3/9/17
    With this method all the history pics would be lost.