15

LINE is a messaging/call application.

I bought a new Android phone, and want to transfer LINE friends, chat history, call logs, groups, groups chat history, from my former Android phone.

How to do?

0

5 Answers 5

6

Official backup / restore solution for Android, introduced by LINE by 2018 for all regions

Limitations of this method

Restored: Chats, Contacts, Media not older than a few weeks

Not restored: Sealed letter messages, Group chats, Media older than a few weeks

Perform on old Phone

  1. Make sure you set an Email and Password for your LINE Messenger account
  2. In LINE, go to your friends list
  3. Open Cogwheel (top right)
  4. Open Chats
  5. Open Back up and restore chat history
  6. If Google account has Not set written below, click on it
  7. Choose your Google account and click OK
  8. Select Back up to Google Drive
  9. Make sure the date on Last backup is the current day and time

Perform on new Phone

  1. Install LINE Messenger
  2. Login with your Email and Password
  3. Go to the friends list screen
  4. Open Cogwheel (top right)
  5. Open Chats & Calls
  6. Open Back up and restore chat history
  7. If Google account has Not set written below, click on it
  8. Choose your Google account and click OK
  9. Choose Restore
3
  • Note: This requires giving LINE the "Contacts" permission (you can create a separate Google account to prevent LINE from seeing all of your Google contacts). Commented May 16, 2018 at 3:32
  • 1
    I have pressed "Back up to Google Drive", and now "Last backup" shows todays' date and "Total size: 5.00 MB", but strangely the associated Google Drive account has nothing new (it is actually totally empty). Do you see a LINE backup file in your Google Drive? Just in case I checked my main Google account's Drive too, nothing new there either. I am checking with Google Drive's web interface so it is not a sync problem either. Commented May 16, 2018 at 3:34
  • 1
    That sounds correct, Google Drive stores app data without it being visible to the user. More info here: developers.google.com/drive/android/appfolder
    – Darcinon
    Commented May 17, 2018 at 22:07
10

Warning: LINE only allows one active phone, and will destroy data on the old phone as soon as you log in on the new phone, so be sure to correctly perform this procedure BEFORE logging in on the new phone.

Fast procedure (requires rooted phones)

  1. If you don't remember your LINE PIN code, now is the last chance to change it, LINE will ask for it after you switch. Even if you never set one, it will ask you so better set it now.
  2. Make sure Letter Sealing is disabled in Line settings on your old phone (you can re-enable it after this is complete).
  3. Root both of your Android phones, old and new (absolutely required)
  4. Install Titanium Backup (free) on both phones.
  5. On the old phone, make sure LINE is not running, launch Titanium backup, and backup LINE (App+Data).
  6. Copy the Titanium Backup folder (typically /sdcard/TitaniumBackup/) from your old phone to your new phone. It should contain 3 files or so.
  7. On the new phone, install LINE (don't start it yet), launch Titanium Backup and use it to restore LINE (App+Data). Press "Done", do not start it yet.
  8. On the new phone, install Root Browser, and use it to copy /data/data/jp.naver.line.android/databases/naver_line to your /sdcard/, then transfer it to a desktop computer (via ADB or email)
  9. Open this file in SQLiteBrowser, go to the Execute SQL tab.
  10. Type delete from setting; then press the Execute button. Click "Write changes" then exit, and copy the modified file back to /data/data/jp.naver.line.android/databases/naver_line
  11. Start LINE on the new phone and log in. When Line asks you about restoring the chat history; say no. Even though Line warns you about loosing your chat history, just go head; all of your data will be just like you left it.

This restores your friends, chat history, call logs, groups, groups chat history.

Note about Letter Sealing: if you forgot to disable it in step 1, new incoming messages will show up as an error and you won't be able to send messages. To fix this problem, just:

  1. Disable Letter Sealing.
  2. Use Root Browser to remove all files that start with "e2ee" in /data/data/jp.naver.line.android/databases.
  3. Re-enable letter sealing.

Thanks to TechGravy for the procedure. Thanks to YandereSan for the Letter Sealing fix.

Slow procedure (no rooting needed)

If you are unlucky enough to have a phone that can't be rooted (the old one or the new one or both), then your only option is this:

  • One-by-one for each chat conversation, go to the conversation settings and backup it (Backup all) to the SD card (or email if you prefer).
  • Move the resulting files to the new phone in a folder called /sdcard/LINE_Backup.
  • Log into LINE on your new phone. This will destroy all history from your old phone, so only do it when all conversations have been backed up.
  • For each of your friends, go to the conversation, chat settings, and tap Import chat history, confirm.

In total this will take about 1 minute per friend if you are fast, for instance about 3 hours if you have 200 friends.

Warning: Groups chat history can not be restored by this procedure. This only restores friends, chat history, call logs, groups. Also, it loses any media older than a couple of weeks.

4
  • This answer is essentially obsolete. I just transfered an account from one Android phone two another by just registering an E-Mail (account settings) on the old phone, then making a backup to google drive of the chat history. Login on your new device. Your contacts should be restored. Now restore your chat backup on the new device. Here the basic procedure is described recovery-android.com/social/carry-over-line-account.html
    – Grmpfhmbl
    Commented Dec 15, 2017 at 16:48
  • @Grmpfhmbl: Nice to hear that it has gotten easier! Could you please post an answer describing the procedure, as external pages tend to disappear? Thanks! Commented Dec 18, 2017 at 4:21
  • 2
    I found out (too late) that the backup/restore all chat option loses any media older than a couple of weeks. Commented Oct 9, 2018 at 22:02
  • @NickWestgate: Thanks for the tip, I integrated your info into the answer, is it correct? Thanks! Commented Oct 10, 2018 at 5:31
2

ROOT 2020-06: Transfer all data locally and allows for 2 phones with the same LINE account

An updated version of @nicolas-raoul 's answer, for when your phone is ROOTed. The following procedure does NOT require uploading your private chats to Google (everything is done locally). Works with Letter Sealing.

Disclaimer: These steps worked for me, and I tried to be as detailed as possible. I'm not responsible for any loss of data, or other damages. Try at your own risk.

Situation my transfer succeeded

  • Tested with a transfer from Android 9 (OnePlus 3) to a new Android 10 phone (Samsung S20+) (through a computer)
  • Both phones ROOTed (with Magisk) and still working
  • LINE Version: 10.9.3 (old phone) - 10.9.3 (new phone) (v9.7.0 gave me a black screen on Android 10 following the instructions below, so I updated to the latest version on the time of writing through the Play Store)
    • Letter Sealing is ON
  • Computer to transfer files from and to your old/new phone
  • Turned off wifi / mobile internet to not receive new LINE messages during the transfer process.
  • Warning: Pictures did not show in chat after transfer. Maybe I should have transferred these images first. Or filesystem path changed, hence it cannot find the images?

Preparation

Locate settings_ssaid.xml on your old and new phone. Likely can be found in 1 of these locations (what I did and what the below instructions assume):

  • /data/system/users/0/settings_ssaid.xml
  • sbin/.magisk/mirror/data/system/users/0/settings_ssaid.xml Or you can use an app like Android ID Editor to find/edit an app's Android ID (untested)

Steps on your old phone

  1. Make sure your LINE is registered with an Email address and Password that you remember (More -> Settings (cogwheel right-top) -> Account)
  2. Get Android ID (which is unique per app since Android 8+; Before 8, it's your device's Android ID)
  3. With a file browser that has ROOT access (I used Total Commander), access the file settings_ssaid.xml (see Preparation step)
  4. Search for "line" and you should find something like: <setting id="xxx" name="yyyyy" value="aaaaaaaaaaaaaaaa" package="jp.naver.line.android" defaultValue="bbbbbbbbbbbbbbbb" defaultSysSet="false" tag="null" />. Copy+paste this line (or whole file) somewhere outside your phone.
  5. Close Line and backup with Titanium Backup. This created 2 .apk.gz and 1 .properties files for me.
  6. Use another app to create an .apk of your current LINE version (in case TitaniumBackup cannot restore the app itself, what happened to me)
  7. Transfer your LINE app backup (Titanium Backup) to your new phone (e.g. through your computer). Check that the backup files are not 0 Bytes (something went wrong then).

Steps on your new phone

  1. Install Titanium Backup (or other app) and an app that can edit SQLite databases (e.g. SQLite Editor)
  2. Copy the Titanium Backup of your LINE app+data to the storage on your new phone (likely 3 files).
  3. Check if Titanium Backup shows a "Restore" button (DO NOT OPEN THE APP AFTER INSTALL):
  • If yes, tap this (if it's taking 5+ minutes (my case), it's not working. Restart phone and follow "no" steps)
  • If no, something might have gone wrong, but you can try these steps:
    1. Install LINE (through the .apk) with e.g. a file browser OR Play Store if you had the newest version (my case)
    2. Start the app once and close it again (this should create an entry for LINE in settings_ssaid.xml on your new phone)
    3. Titanium Backup's "Restore" button should have appeared now, tap this and select "Data only"
    4. Do NOT open LINE yet
  1. Go to your phone's settings -> Apps -> LINE -> Storage -> Data should NOT be 0 B (this means Titanium Backup has failed)
  2. In relation to settings_ssaid.xml (Android 10):
  3. Open settings_ssaid.xml
  • If you can find jp.naver.line.android: change the values to of value and defaultValue to values found on your old phone (aaaaaaaaaaaaaaaa and bbbbbbbbbbbbbbbb, respectively) - (untested) If not found: Copy the whole <setting id ... tag="null" /> and change id to 1 higher than the other apps (e.g. setting id="27")
  1. If permissions were changed on save, restore original values (probably did not happen if you used Total Commander)
  • File permissions: Owner-only RW; value=600; UID: 1000 system; GID 1000 system
  1. Open your SQL editor app, give it root access, and navigate to: /data/data/jp.naver.line.android/databases/naver_line. If using SQL Editor:
  • Use File explorer (not Apps list)
  • If you cannot see naver_line, press the 3 dots right-top and uncheck "Show only database files" (it's a database file, but without extension)
  • Open naver_line -> setting -> delete everything with specific phone info (I deleted entries here on a a previous transfer, so I forgot what I deleted, sorry)
  1. (untested) Copy LINE images received in chat to new phone.
  2. Restart your phone (otherwise Android ID change won't take effect, and LINE will crash)
  3. Start LINE:
  • If you see your chats, congrats, you now have LINE working on both phones :D
  • If you get an error saying LINE detected a new phone, do NOT continue. If you continue, LINE will erase all your messages. Go back to the SQL editor step, and delete more entries that could tell LINE that it's not your old phone.

I figured this stuff out with the help of the following resources:

2

Root solution for fresh install and old database

Example situation

You lost your old phone, the other root solutions do not work here, but luckily you have a backup of naver_line database found in jp.naver.line.android/databases/naver_line (maybe you have set up Syncthing to always have the latest version)

You have installed NAVER LINE on your new phone, but were not able to set your chat history back at first startup.

Solution

  1. Download "DB Browser for SQLite": https://sqlitebrowser.org/
  2. Open the latest naver_line DB with DB Browser
  3. Click "Attach Database" in toolbar and select your old naver_line
    • When searching for your file, change "Files of type" to "All files (*)" (naver_line file has no extension)
  4. Write SQL code to merge the 2 databases
  5. Copy the merged database to your Android phone
  6. Set the UID and GID to LINE
  7. Rename the new app's current naver_line db and copy your new merged db into e.g. /data_mirror/data_ce/null/0/jp.naver.line.android/databases
  8. You got your chat history back!

Limitations

  • Not sure how to recover images shared in chat yet.
  • Chats that haven't seen a new message since you reinstalled LINE do not show up (but have all your chat history)
    • These do appear if you select the chat from your home screen. The message will be shown as from 1970/1/1 though
  • Search for old chat history seems broken :/ Even after you have opened an old chat.
-1

Another "Fast procedure" for un-rooted phones is by using a 3rd party tool called Backuptrans Android Line Transfer. You need to follow these steps:

  • Connect both your Android Phones to computer via USB cable. (Make sure USB debugging is enabled on phone)
  • Run the Android Line Transfer program on computer. Choose the source device on the program and then click the "Transfer" icon.
  • Choose your target device and wait the transferring to be done.

That is it.

2
  • 2
    I see "Personal Edition USD $19.95", there is no free version I guess? I looked for feedback about this tool, and find it strange that nobody on the Web is talking about it, Google only finds the product's download pages and your answer here. Commented Apr 10, 2016 at 8:24
  • My experience with Backuptrans Android Line Transfer was hit and miss. Backing up from a Samsung J7 went fairly smooth though the software is slow and lags a lot. Transferring the same backup to an OPPO F1S Plus didn't work, the phone was recognized but would not cooperate with the software. (Restoring to a different model may have went smoother but I didn't try). I then had to restore the back up to the J7 again which took 3 attempts. I spent 4 1/2 hours doing this whole operation. I think better doing it the Line chat by chat method could be better. Backuptrans Android Line Transfer is the r Commented Dec 28, 2016 at 10:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .