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.

In the spirit of taking responsibility for my own data, I regularly fetch my gmail emails via IMAP for backup.

However, this doesn't include the Google Talk chat logs which are also available in Gmail. Is there a way to export those logs? The data liberation front doesn't seem to have any information about google talk.

share|improve this question
    
+1 for responsibility, although the chance the 1. Google will withhold this data in the future (willingly or not) and 2. Your backup will be available are negligible, IMHO. –  ripper234 Nov 6 '10 at 10:48
1  
@ripper234: The most likely data-loss scenario is probably that I accidentally delete the wrong emails and empty trash before realizing my mistake. I learned my lesson that time when I accidentally did rm -rf * in my home directory. –  Wim Coenen Nov 6 '10 at 13:01
    
I see. I never delete any email, just archive everything. –  ripper234 Nov 6 '10 at 16:01
    
Vote on it. google.com/moderator/#15/e=1d33&t=1d33.40&q=1d33.1536c –  clee Apr 20 '11 at 23:37

7 Answers 7

up vote 8 down vote accepted

The IMAP interface to Gmail now provides access to chat messages. If you had already set up Gmail IMAP, then you only have to enable the IMAP visibility for the "Chat" label in the Gmail settings (in the "Label" tab, a "show in IMAP" tick box is available for each label).

Update: this method works for Google Chat, but NOT for Hangouts, only conversations of the type Google Chat are exposed via IMAP, roughly all conversations until Spring/Summer 2013, depending on when one has enabled Google Hangouts.

Sources:

The latter link provides an alternative to download via Google Takeout in the JSON format

share|improve this answer
5  
Naked links don't make great answers. Please summarise the post here, just in case the blog gets deleted or changes it's URL. –  ChrisF Nov 9 '11 at 15:46
    
google gears doesnt work now any other alternative? –  BlueBerry - vignesh4303 Jul 29 '13 at 11:53
    
The fastest way for now (2013/2014) seems to be Google Takeout. google.com/settings/takeout/custom/chat Only problem is, it did not work for my hangouts, only got "404. That’s an error. The longer, harder, but readable way is to open the hangout history, scroll, scroll, scroll until all gets loaded, copy and paste into a word program, save. Not nice but works. The requested URL was not found on this server. That’s all we know." :( –  Echt Einfach TV May 9 at 15:51

Forward them to an email address you have POP/IMAP access to.

share|improve this answer
1  
Filters don't seem to be applied to new chat logs (maybe I need to wait longer?) But I guess the "also apply to x conversations below" checkbox would indeed export all existing logs in one swoop, so +1 –  Wim Coenen Jul 7 '10 at 22:46
    
@Wim Coenen: Edited to next-best thing. –  Gelatin Jul 8 '10 at 14:17

There is no explicit way of exporting your Google Chat logs through a Google provided function but there are a number of different alternative methods which seem to be available.

  1. The first, as mentioned by Simon, is to forward them to an email address where you can download them via POP/IMAP.

  2. You can install the "Create a Document" labs experiment for Google Mail which allows you to create a document for each chat. This could be quite laborious though and then you have to backup from Google Docs, which is another step.

  3. There appears to be a python script here which backups Google Chat logs. However, in the comments there appears to be some issues with being temporarily locked out if you download too much at once.

share|improve this answer
    
How do you forward them? –  endolith Jul 25 '12 at 3:43

Have a look "How to do that", without use of any software http://digivorous.blogspot.com/2010/11/how-to-download-and-backup-your.html

share|improve this answer
1  
+1 this looks like a good solution. But did you get permission from the author of the original post at martinml.com/en/… to copy that much of his work verbatim? I think it would be better if your blog post just linked to his post, and offered your own alternative vbs script. –  Wim Coenen Nov 6 '10 at 12:15

You could make a filter in GMail to do the heavy lifting for you. When making a new filter, put "in:chats" in the "Has the words:" blank, and then choose the action you want to take (such as forwarding).

By the way, it's useful to note that the "Has the words:" blank functions just like the search bar above (as far as I can tell), so you can enter all kinds of search operators in there to make really complex filters!

share|improve this answer
    
It looks like new chat logs are a special case, filters are not applied to them. (Though applying the filter to existing matches while creating it may work). –  Wim Coenen Jul 8 '10 at 21:37
    
Well, as the warning indicates, filters which contain "label:", "is:", or "in:" in the "has the words:" blank will not apply to incoming mail. Presumably, chats fall into this category. This method could still, however, be useful. For instance, if you do a typical search (in the search bar) for in:chats, you'll get all the chats, but can't forward them. The filter (although you'll have to run it manually every once in a while) turns up the same search results, though, and also allows you to take action upon those results (e.g., forward them). –  jrc03c Jul 10 '10 at 0:18

none of the forwarding labelling filtering solutions work...

"no old mail will be forwarded"

  • it appears that option 3 is the only solution that may work - but even that has the risk of being locked out for 24 hours - or whatever.

AMAZING! - Why is it that we cannot access the chat logs? is there some legal issue? I have searched for this on many occasion and always give up.

There isn't a clear answer that I can find anywhere and all the supposed answers come up short... and last time I tried, I could not get the Python script to work - but then I was on x64, and not very familiar with Python in the first place. I am about to try again - crossing my fingers.

share|improve this answer

I have figured out a way to get them out via forwarding them, using a browser scripting tool call iMacros. I think this macro will only work with Firefox 3.6 which you can get from this link. I wont go into installing and setting either of them up, but here is the macro I used.

VERSION BUILD=7300701 RECORDER=FX
TAB T=1
FRAME F=4
TAG POS=1 TYPE=SPAN ATTR=CLASS:hE&&TXT:Reply
WAIT SECONDS=.5
TAG POS=1 TYPE=TEXTAREA FORM=NAME:NoFormName ATTR=NAME:to CONTENT=test@GMAIL.COM
TAG POS=1 TYPE=DIV ATTR=TABINDEX:1&&ROLE:button&&TXT:Send
WAIT SECONDS=3
TAG POS=1 TYPE=IMG ATTR=ALT:&&SRC:images/cleardot.gif&&CLASS:iHkD0e&&TXT:
WAIT SECONDS=2

Just replace 'test@gmail.com' with the email address you want to forward to.

Now the only other key piece of advice is where to start the loop of the macro. To do it right, you will want to create a label and assign all your gmail chats to it. This will allow you to see your chats in chronological order and forward them that way.

Then in gmail click on the label, when the list opens it will likely open to the newest first. Therefore, go the the last page of the labels contents. Open the last item. here is when you click "play loop" in iMacros.

I had 1k chats to export. You'll notice there are "wait" statements in the code, this will give the browser time to keep up. They may need tweaking.

Also, check back every couple of minutes, because it sometimes throws an error, or tries to move to the next (newer) chat before the email has been sent. Just click "cancel" and it will go back to the script and the email will have been sent.

If it throws any other errors during operation, you should be able to adjust the loop duration and start it again with no problems.

This has been aggravating me for so long since I switched Gmail accounts due to spam, so I am finally happy to close that account having got all my content out.

share|improve this answer

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.