Reputation: 499
Does anyone know if there is any official documentation for google spreadsheet embed URL paramaters?
That is, given an embed URL from Google Sheets like this: https://docs.google.com/a/aicr.org/spreadsheet/pub?key=0AhExuVBhVYT1dGxxejBmUHAzYUhGb25veTRkdW1YekE&single=true&gid=1&output=html&gridlines=false
After much digging and searching, I have found:
... and no search I have done has produced anything even remotely approaching either of:
By trial and error I have found:
Upvotes: 44
Views: 46181
Reputation: 462
The most helpful list of parameters I found comes from Steegle.com.
You can use the htmlembed URL to display just a range from a Google Sheet - here's how to structure the URL
https://docs.google.com/spreadsheets/d/SpreadsheedID/htmlembed?single=true&gid=SheetID&range=D15:E15&widget=false&chrome=false&headers=false
SpreadsheedID
should be the long letters, numbers and characters you get in the normal URL
htmlembed
is for sheets you have not published: use pubhtml instead if you have chosen to publish the sheet (if you want the public to see it it's the best way
single
never been sure what it does, but we think it helps with only showing a single sheet instead of multiple sheets
SheetID
is the sheet number you get in the normal URL after the ?gid= (this is not the sheet name you have specified but the automatic number that Google Sheets provides)
range
lets you specify the range of cells you want to display
widget
lets you choose whether to display the sheet tabs at the bottom
chrome
lets you choose whether to display the spreadsheet title (& sheetname) at the top
headers
lets you choose whether to display the spreadsheet title at the top
Upvotes: 2
Reputation: 6733
Here are some of the parameters I found for Google Docs (thanks goes to Joel http://obstruction.tumblr.com/post/60784440737/google-docs-url-parameters-rm-minimal-rm-full):
Google Docs URL parameters:
rm=minimal
rm=full
rm=embedded
rm=demo
rm=(render mode)
ui=2 (select the interface version)
chrome=false (full screen mode)
frameborder=(size of border)
q=(Whatever) Search Query
gid=24 (Which sheet you want to display)
widget=false
single=true
range=A2:AA26 Output=html
format=(export spreadsheet)
format=xlsx
format=csv
widget=false
width=(width)
height=(height)
viewer?
start=
channel=
ibd=
client=
Upvotes: 25
Reputation: 86
I've been looking for the same thing! One more URL parameter I have found useful is
This resource describes some of the parameters, though I can't vouch for its accuracy. http://www.goopal.org/google-sites-business/google-spreadsheets/spreadsheet-output/publish-spreadsheet#TOC-Other-Export-Parameters
Upvotes: 4