How To Join Google Sheets

Google Sheets, a cloud-based spreadsheet program from Google, offers numerous powerful features for data manipulation and analysis. One of those powerful features is the ability to join tables of data together, similar to how you might in SQL. In this blog post, we will guide you through the simple process of joining two Google Sheets together using the =QUERY() and =IMPORTRANGE() functions.

Step 1: Set Up Your Sheets

Create or open up the two Google Sheets that you want to join. For the sake of this guide, let’s name them “Sheet1” and “Sheet2”. Make sure both sheets have at least one column of data that matches exactly. This matching column will serve as the key to join the two sheets.

Step 2: Use the IMPORTRANGE Function

=IMPORTRANGE() function imports a range of cells from a specified spreadsheet. The syntax for this function is: =IMPORTRANGE(spreadsheet_url, range_string).

Here’s an example of how to use it:

    =IMPORTRANGE("", "Sheet1!A1:C10")

This formula will import cells A1 through C10 from Sheet1 of the specified spreadsheet URL. You’ll need to replace the URL with the URL of the spreadsheet you want to pull data from.

Step 3: Use the QUERY Function

Now, let’s move on to the =QUERY() function. It allows you to perform a query over an array of data using Google Visualization API Query Language.

Here’s an example of how to use it:

    =QUERY(IMPORTRANGE("", "Sheet1!A1:C10"), "select Col1, Col2 where Col3 > 500")

In this formula, we not only import data from another sheet but also select specific columns (Col1 and Col2) where the value in Col3 is greater than 500.

Step 4: Join the Sheets

Now, you can use both =QUERY() and =IMPORTRANGE() functions together to join your sheets. Here’s how:

    =QUERY({IMPORTRANGE("URL_Sheet1","Range_Sheet1");IMPORTRANGE("URL_Sheet2","Range_Sheet2")},"Select * where Col1 is not null")

In this formula, replace URL_Sheet1 and URL_Sheet2 with the URLs of your sheets, and Range_Sheet1 and Range_Sheet2 with the specific ranges you want to import.

And that’s it! You have successfully joined two Google Sheets. Now you can easily manipulate and analyze your data without having to constantly switch between different sheets.


Joining Google Sheets is a powerful way to consolidate information from multiple sources, which can enhance your data analysis and decision-making process. We hope you found this guide helpful. Stay tuned for more tips and tricks on how to make the most out of Google Sheets.