37

Has anyone discovered where/how offline Google Documents are stored when using Google Drive in Chrome? They must be stored locally but where?

Have tried the browser cache etc but can't see it unless I'm missing something very obvious!

To clarify, the file that is stored within 'My Documents/Google Drive' is a text file with a URL, what I am looking for is where the file that the URL points to is held when in offline mode.

MPelletier
  • 16,256
  • 15
  • 86
  • 137
pjpeers
  • 373
  • 1
  • 3
  • 6
  • Shouldn't that be in the "Google Drive" folder in "My Documents"? – simaglei Oct 09 '12 at 09:47
  • The offline file that Google stores in 'My Documents/Google Drive' is just a .txt file with a URL. Note this is for Google Documents, I'm sure .doc formats probably are stored within this particular folder. – pjpeers Oct 09 '12 at 11:09
  • Upload to GoogleDrive something big, go offline and see which folder size increased. – spyder Nov 30 '12 at 09:06
  • I guess we're all too lazy to actually try this. :-) I know I am - thus the bounty. Actually, I was hoping somebody would already know the answer. – DaveGauer Dec 04 '12 at 23:45
  • @DaveGauer laziness, impatience, and hubris? :) – spyder Dec 05 '12 at 03:14

7 Answers7

39

It turns out the offline documents are stored in the HTML5 FileSystem.

The Chrome FileSystem storage is located here on my Windows 7 machine:

C:\Users\<username>\AppData\Local\Google\Chrome\User Data\Default\File System

I added a number of large images to a document with the Chrome "Offline Docs" enabled and was able to see the FileSystem storage directory grow appropriately.

I then used the HTML5 FileSystem Explorer extension for Chrome to view the file structure of an offline document and was able to confirm that the images were, indeed being retrieved from the HTML5 FileSystem when Chrome was offline. See screenshot:

screenshot of an offline google drive document and its storage of a document in filesystem

DaveGauer
  • 1,255
  • 14
  • 25
  • 7
    Wish I could give myself a bounty. – DaveGauer Dec 05 '12 at 03:57
  • I suspected that the actual files would be on the file system, that's why I wrote that IndexedDB contains data _about_ files. BTW, functionality in that extension should be built into Web Inspector. – MeTTeO Dec 05 '12 at 08:07
  • @MeTTeO Yeah, I did catch the distinction in what you wrote. And I think you're right about that too - it does appear to use the IndexedDB for various purposes while using the application. As for the built-in resource viewer in Chrome, I agree with you - it sort of does the same thing (as the HTML5 FileSystem Explorer Extension), but it was far less readable and I couldn't figure out an easy way to actually open the "files" in the browser like I could with the extension. – DaveGauer Dec 05 '12 at 16:55
  • 1
    Just wanted to say thanks Dave, and apologies for not showing my appreciation sooner! – pjpeers Jan 28 '13 at 16:17
  • 1
    This does not appear to be true any longer. As best I can tell storage is now in `C:\Users\\AppData\Local\Google\Chrome\User Data\Default\Local Storage` in a file like `https_drive.google.com_0.localstorage`. – feetwet Mar 10 '17 at 20:22
  • 3
    Looks like the HTML5 FileSystem Explorer extension that you used for this excellent sleuthing is defunct (dead link). Do you use something different nowadays? – bhagerty Nov 04 '19 at 20:04
10

Further, it may interest you, the location where Google Drive stores offline docs in Android's file system.

sdcard/android/data/com.google.android.apps.docs/

JNevill
  • 46,980
  • 4
  • 38
  • 63
user2229720
  • 101
  • 1
  • 2
  • Thanks for the tip! A folder inside it is named "files\pinned_docs_files_do_not_edit" and the folders within are long random strings with actual files inside them. – Naidu Ypvs Aug 01 '13 at 10:05
  • 1
    I can't play any of files there? Are they encrypted. None of my Android media players can play the songs. – Saeed Neamati Jan 19 '14 at 07:43
6

Google Drive uses Chrome's IndexedDB for storing data about files. To see the contents, open developer console (Ctrl + Shift + I) and choose Resources tab.

This answer tells you about actual location of IndexedDB in the file system on Windows.

On Linux it's: ~/.config/google-chrome/Default/IndexedDB

Community
  • 1
  • 1
MeTTeO
  • 2,088
  • 16
  • 19
  • This looks like the right answer. On my Windows 7 machine, Chrome's IndexedDB data for the Docs/Drive site/app was located here: C:\Users\\AppData\Local\Google\Chrome\User Data\Default\IndexedDB\https_.docs.google.com_0.indexeddb.leveldb. I watched it grow in size as I edited a new document on Docs/Drive. I can't confirm that it actually contains all of my offline documents, but that appears likely given its current size of 32Mb (the other IndexedDB directories are all much, much smaller.) – DaveGauer Dec 05 '12 at 00:03
  • Nope, turns out that was wrong. The IndexedDB was definitely being written to while I was in Docs, but it wasn't actually being used as the persistent storage for offline mode. – DaveGauer Dec 05 '12 at 03:56
1

On my computer (Windows 8.1 / Chrome version 41.0.2272.101 m) I found the filesystem at "C:\Users\my username\Appdata\Local\Google\Chrome\User Data\Profile 1\File System"

I needed to find it because I had some corrupted images in Google Slides (they worked on other computers or other browsers on my computer, just not in chrome on my computer). I deleted the File System directory and shazam, the images reloaded and were no longer corrupted.

0

Mine were all stored in

C:\users\%username%\Google Drive\

Have you downloaded Google Drive?

gaynorvader
  • 2,619
  • 3
  • 18
  • 32
  • With the exception of file types not native to Google Docs, the Google Drive directory only contains a series of URLs pointing at the actual documents being stored online. See pjpeer's comment on simaglei's answer. – DaveGauer Dec 04 '12 at 23:44
-1

Offline access is available only when you’re using Chrome. See Setup Offline Access and Google Docs Offline. It seems like offline documents are encoded by Chrome and stored at some secret places, in order to force you to use Chrome.

darcyy
  • 5,236
  • 5
  • 28
  • 41
-1

Google drive stores the offline files in a folder called... android/data/com.google.android.apps.docs/files/pinned_docs_files_do_not_edit/ in that folder u will find the desired files. Please be aware that... The files that you will find can be of two formats.. 1) encrypted 2) open type

If you have left unchecked the option to encrypt (by default in google drive) the files that u downloaded will be visible, but not accessible by the standard reader. every attempt to read it will be result in a failed operation. But ... if you DISABLED the encryption in google drive, u will be able to open freely with any type of reader.

jeff porter
  • 6,560
  • 13
  • 65
  • 123
  • 1
    There is a file that is labeled for offline storage, but it does not show in the Android file system under the path: `android/data/com.google.android.apps.docs/files/pinned_docs_files_do_not_edit/` When the file is downloaded from Drive it does show under _Downloads_ in the file management app and is read successfully. However, it is preferred to find the files' path without needing to download it. Any thoughts are appreciated! – AdamHurwitz Apr 04 '20 at 08:05