# Google Sheets

{% hint style="info" %}
💪 **Difficulty:** medium

⏳ **Time to complete**: approx. 5 minutes
{% endhint %}

## 💬 Description

In this context, Google Sheets is one of the most helpful Connectors we’ve built. It helps us bring custom and annoying data into your database every day.

Less’ will not use data transferred from Google API’s (as with any other Less data source) unless explicitly requested by the client. Less thus comply with [Google API Services User Data Policy](https://developers.google.com/terms/api-services-user-data-policy).

## 🤑 Use Case

We use Google Sheets for budgets, financial projections, costs that don’t exist in our accounting system, and many other things. Essentially the Connector can be used for all data that is maintained manually and can’t be extracted with a Connector.

## 🛠️ Setup

This one is pretty manageable if you are used to working in Google Sheets. If some parts don’t work or the data doesn’t turn out the way you want, please [schedule a call](https://calendly.com/thomas-less/speak-to-less) and we’ll figure it out together.

### Step #1: Authenticate through Google

Right after you click connect you’ll be redirected to the view below. Select the account your Google Sheet is connected to and click “Allow” in the next step. You’re giving Less permission see view your Google Drive and Sheets data.

<figure><img src="/files/lGJTmXh7ucQ6KGHNmyFp" alt=""><figcaption></figcaption></figure>

### Step #2: Name your table

Back in Less, you should input what you want to call the table. You can name it whatever you want.

### Step #3: Input the sheet URL

Navigate to the sheet you want to extract data from. Copy/Paste the URL into the field that’s called Input Sheet URL.

<figure><img src="/files/vDxh6HvsyXuMxFE1br4N" alt=""><figcaption></figcaption></figure>

### Step #4: Input data range

A data range is essentially an area in your Google Sheets that contains the data you want to export. You can do this in two ways:

#### 4.1 Directly input a data range

Simply input {{sheetname}**!**{{starting\_column}}**:**{{ending\_column}} in the Less configuration window. If your Google Sheet is called *Budget* and you want to extract all data in columns A to D, you should input **Budget!A:D**. Spaces in sheetnames are not a problem.

Note that the sheet name is in the one bottom left-hand corner. **Not** the one at the top of the document.

<figure><img src="/files/6c5uiyKMvZZ1Z7pEagXA" alt=""><figcaption><p>Sheet name vs. document name</p></figcaption></figure>

Select how often you want your Google Sheet Connector to update and click *Save Changes.*

#### 4.2 Create a static data range&#x20;

If you navigate to **Data**, click something called **Named Range** (see below)

<figure><img src="/files/MB02Wn1L972PtgWnnB6C" alt=""><figcaption></figcaption></figure>

After clicking Named Range, you’ll the pop-up to the right below.

1. First (1) input a Name (this is the one you need to input in Less)
2. Second (2) click the little grid icon and mark the area you want to export. **Here is it important that the first row contains the headers of your data table**. Also, make sure there is no formatting on the cells (Format → Number → Automatic).
3. Lastly (3) click **Ok** and **Done**. Take the name from (1) and input in Less (in the screenshot that would be Less\_Google\_Sheet

<figure><img src="/files/HBeVzyKO6pPS6jrEO3Jm" alt=""><figcaption></figcaption></figure>

Select how often you want your Google Sheet Connector to update and click *Save Changes.*


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://resources.less.tech/less-tech/connectors/connector-guides/google-sheets.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
