Take the 2-minute tour ×
Web Applications Stack Exchange is a question and answer site for power users of web applications. It's 100% free, no registration required.

How can I download all my private messages from Facebook?

I don't really want to have to scroll through the actual messages, wait for older ones to load, and copy and paste since I have 7k+ messages so far.

I tried downloaded my messages through Facebook's archive thingy, but it only seemed to save the latest 20-30 messages per person, and not every message.

I'm now trying to download Facebook's extended archives, but based on the FAQ questions, but idk if it'll have the rest of my messages.

Edit: I gave it another try, and it looks like this is no longer the case.

I'm open to any solution.

share|improve this question
add comment

8 Answers

up vote 7 down vote accepted

To download your data, log into Facebook, then click the little arrow in the top right and select "Account Settings".

In the bottom left of your "General Account Settings" find the line of text that says "Download a copy of your Facebook data" and click the link.

enter image description here

share|improve this answer
    
Huh, interesting. When I first tried this in June, Facebook gave me only the 20-30 most recent messages in the archive, but now it gives me all of them. (it takes forever to archive everything, but oh well) –  Michael0x2a Nov 26 '12 at 5:24
    
+1 This seems to be the only thing that really works. I'm still surprised there's no Facebook app for this, since the Facebook API seems to allow access to messages. –  E M Oct 19 '13 at 15:35
add comment

You can try going to http://m.facebook.com/ and click on "Messages".

Select a person to view the history, and click on "See Older Messages" once.

Notice that &start= part in the URL, that's the number of received and sent messages minus 7.

Notice the &page_size=7 part in the URL. Currently, Facebook does not limit this number, you can set that to a number bigger than the start value. This makes it disable pagination and displays all the messages it found, except the skipped 7. (If the number's smaller, somehow Facebook will display only 7).

** To make it work on Chrome, left click on "See Older Messages" and choose "open in a new tab" and there you will find the "page_size=" number to change. (May 2013)

share|improve this answer
    
Interestingly, this appears to work only in Firefox and IE, but not Chrome. I'm not really sure why. –  Michael0x2a Sep 3 '12 at 6:30
    
Doesn't work for me in Firefox, either. Chrome just doesn't show start and page_size URL parameters - the URL is completely different. Firefox shows them, but changing page_size seems to have no effect - I still see only a few messages at a time. –  E M Oct 19 '13 at 15:27
    
this works, this is great to get to the start of the conversation. But you have to go through each pages to get the whole thing. –  David 天宇 Wong Dec 15 '13 at 13:52
add comment

I use a tool called SocialSafe that backs up all of (well, pretty much all of) my Facebook content, and that now includes messages. I can search through them all, and also jump see in the little diary part of it all of the different things that I've done on Facebook over the years.

share|improve this answer
    
But does it allow you to save them to a file on your disk? If so, in what format? Are emoticons, links, etc. included? –  E M Oct 19 '13 at 15:27
add comment

So, I managed to hack together a solution:

Facebook (at the time of writing) loads old messages if you scroll all the way to the top, with the newest messages being kept at the bottom.

I wrote a Greasemonkey script to force the webpage to constantly jump to the top, making Facebook load approximately 6000 messages in about 5-8 minutes. I then copied and pasted everything to a text file, which I can later parse and prettify at my own leisure.

The script is below:

// ==UserScript==
// @name        ScrollToTop
// @namespace   Deflect
// @description Perpetually scrolls to the top of the screen until disabled.
// @include     *
// @version     1
// ==/UserScript==

var amScrolling = false;

var perpetualScroll = function () {
    var createLink = function () {
        var scrollLink = document.createElement('a');
        scrollLink.className = (scrollLink.className || "") + ' topScroll';
        scrollLink.style.display = 'block';
        scrollLink.style.position = 'fixed';
        scrollLink.style.bottom = '1em';
        scrollLink.style.right = '1em';
        scrollLink.style.color = '#fff';
        scrollLink.style.backgroundColor = '#000';
        scrollLink.style.padding = '0.5em';
        scrollLink.href = '#';
        scrollLink.textContent = 'Start Scroll';
        scrollLink.onclick = function (e){
            amScrolling = !amScrolling;
            if (amScrolling) {
                scrollLink.style.backgroundColor = '#333';
                scrollLink.textContent = 'Stop Scroll';
            } else {
                scrollLink.style.backgroundColor = '#000';
                scrollLink.textContent = 'Start Scroll';
            }
            return false;
        };
        return scrollLink;
    };

    var scrollDiv = document.createElement("div");
    scrollDiv.id = "topScroll0x2a";
    scrollDiv.appendChild(createLink());
    document.body.appendChild(scrollDiv);

    var scroll = function () {
        if (amScrolling) {
            window.scrollTo(0, 0);
        }
    };

    var intervalId = window.setInterval(scroll, 50);
};

perpetualScroll();

However, this isn't an optimal solution because a lot of the work is still manual -- if I want to get the messages of multiple users, I still have to either do them one at a time, or open up multiple tabs or something.

If you wanted to, you could probably modify the script to programmatically detect when it's hit the top of the screen, grab all the messages, prettify it, and slap it onto pastebin or something, but I didn't feel like doing all that work.

Edit:

Now that Facebook's changed their UI on the main messaging page, I'm not so sure if this hack works anymore. I'm going to unaccept this as an answer (but leave it as reference), and pick a new one after I've had a chance to try the other ones out.

share|improve this answer
add comment

There is absolutely no provision to download all the private messages from a Facebook account - Facebook doesn't gives any such option.

Also, it is impossible to any Facebook App/API (third party) can ever be made to do it, because no matter what, there is no provision for an app to get access to a user's private messages.

The API can get Profile Pic, Name, Friends Name, What time you log into Facebook, etc... but no way it can get into your private messages.

Only Option

You do it manually - which is not practical or else you can locally have an Internet-bot in your system to do it for you.

Searching through Google, I didn't find any such existing bot, but it is possible to make one.

share|improve this answer
add comment

There is an add-on for Firefox which downloads your facebook inbox and saves it in txt files. Take a look here: https://addons.mozilla.org/en-US/firefox/addon/red1/ or here: http://www.facebook.com/Red1MessageArchiver

share|improve this answer
add comment

http://www.httrack.com/ use this offline website viewer, input your message page url of facebook and let it download all the mesages which you can browse from offline

I guess it should work

share|improve this answer
add comment

Just go to your browsers menu and click "save as" while you're on the page with the messages. Make sure all the messages are showing by clicking to load them each time, until you have scrolled back to the beginning. This will save the entire web page, including your pictures and you will be able to scroll through the message exactly like the original on Facebook. Hope this helps!

share|improve this answer
    
Unfortunately, when you have over 100k messages from one person, this solution doesn't scale. I'd have to sit in front of my computer for days if I want to get to the very start for just one person. –  Michael0x2a Mar 10 at 2:00
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.