Open Any Document in Google Docs Via a Url

August 28th, 2008 by Justin Ball

We are looking at ways to integrate the new Teachers Without Borders site with Google docs.

Turns out that you can open:
documents - .pdf, .doc, .txt, .html, .rtf and .odt
spreadsheets - .xls, .csv, .ods
presentations - .ppt

By feeding the file url to this google url:
http://docs.google.com/?DocAction=updoc&formsubmitted=true&uploadURL=DOCUMENT_URL

Here's an example if you needed to view a W4 form from the IRS url:
http://www.irs.gov/pub/irs-pdf/fw4.pdf

Use this url:

http://docs.google.com/?DocAction=updoc&formsubmitted=true&uploadURL=http%3A%2F%2Fwww.irs.gov%2Fpub%2Firs-pdf%2Ffw4.pdf


http://docs.google.com/?DocAction=updoc&formsubmitted=true&uploadURL=http://www.irs.gov/pub/irs-pdf/fw4.pdf

Tags:   · 6 Comments

Leave A Comment

6 responses so far ↓

  • 1 Fred Sep 1, 2008 at 11:49 am

    You’re the one to do it, Justin!

  • 2 tom Sep 10, 2008 at 3:15 pm

    I am looking for a way to open a “google document” via a URL on a web page (or other allowed locations for such a link) - and I think you are saying you figured out how to do that but the link you provided was truncated. Could you reply to my email tom@gafyd.net and tell me if you know how to achieve what I’m seeking to do….. Thanks Much TOM

  • 3 Justin Ball Sep 23, 2008 at 7:52 am

    I’ve been experimenting with this a bit and it would appear that Google has recently added some security that prevents you from opening a document directly via the url. Not sure why they would do this but personally I have started to find that Google doesn’t really like mashups or useful integrations. They provide APIs but I tend to find them far more complicated than they need to be (why should everything need to be a large atom based document you submit via a post) and far less useful than most. The url hack was an awesome way to make it easy for a user to add a link that let other users import a document into Google docs. Big failure here Google.

  • 4 nikki Sep 24, 2008 at 10:27 am

    Hi, I just tried this and it didn’t work - just sent me right to my docs homepage. Perhaps they’ve changed the google url? Any other suggestions?

  • 5 Justin Ball Sep 24, 2008 at 2:27 pm

    Google shut down this hack so now you have to use their apis which sucks because instead of five minutes to create a link you have to spend two days integrating their api calls and the user experience stinks (they have to login to Google and are required to follow several more steps).

    It was nice when it worked. Wish Google would be more open.

  • 6 rnajan Oct 14, 2008 at 5:12 am

    ita very good facility