blog :: web development :: google spreadsheets rss

How To Export An RSS Feed From Google Spreadsheets

Posted on 25 Apr 2009 by - Permanent link Trackback this post Subscribe to this post Comment on this post -  

I’m a huge fan of RSS feeds and often use them to wire together simple mashups or power more complex web programs. Most online applications need some configuration data, such as a list of data sources, users, locations or timestamps and I don’t like to hard-code these into my programs. It’s much better to use a datastore for configuration information like this.

RSS

When building a mashup of data and services stored in the cloud, the configuration data should be stored (and edited) online too. You can collaborate with others and use delicious.com as database of URLs, as described by Jon Udell, but if you want a nice online form for your configuration data, Google Spreadsheets is the way to go.

It is easy to get data into the spreadsheet by publishing a form, but how to get an RSS feed out of the Google Spreadsheet? It’s not obvious, but Google Documents provides this functionality too. Follow these instructions to publish your spreadsheet as an RSS feed:

  1. Create your spreadsheet and save it, as normal
  2. Click the big blue “Share” button and choose “Publish as a web page”
  3. After publishing, the popup window will show a “Subscribe” link. This is the URL of your RSS feed
  4. Tick the option to automatically republish as changes are made. There is also an option to choose a specific sheet from your document
Popup window showing the RSS link

So there we have it. You can create a nice form to populate a Google Spreadsheet with data, then publish an RSS feed and use it in your mashups.

If you like RSS feeds, don’t forget to sign up to the MMMeeja RSS feed.


Creative Commons licensed photo by lumaxart.

0 Trackbacks

Trackbacks are closed for this story.

2 Comments

 Nash said at 2009-05-13 22:28

more publishing options

Thank you for that simple guide.

At the bottom left of the publishing popup is a great little extra called "more publishing options" to modify the feed.

Question: If I follow the example; "Example: C13, A1:D5, range name", wouldn't that prevent future entries from displaying. Meaning the feed will only show these particular cells.(i.e. I don't want to reveal the email column)

I guess one option would be to build a feed inside the sheet (in another cell) from the desired columns.  Appreciate any feedback.

 

 MMMeeja said at 2009-05-14 01:17

Re: more publishing options

Hi Nash, thanks for stopping by and commenting.

You're right that if you use "more options" to specify a range of cells for your feed, it is limiting. You'd need to constantly check how many rows are in the spreadsheet and modify the URL accordingly.

Using cell ranges to hide data is not very secure either - the range is shown in clear text in the URL so a hacker could alter the URL to see all of your data.

A more secure way would be to have two sheets in your spreadsheet. Sheet1 is updated by the form and sheet2 just takes a copy of the public columns from sheet1. Then make a feed from sheet2 only (see the "What parts" combo in the publishing dialog).

Hope this helps.

Comments are closed for this story.

 

Sitemap

Copyright © 2006-2009 MMMeeja Pty. Ltd. All rights reserved.