How to Use the IMPORTRANGE Function In Google Sheets


IMPORTRANGE function of google sheets allows to use and and import data from an external source into your own spreadsheet with proper permission of access.

Syntax of this function is :

=IMPORTRANGE( spreadsheet_url, range_string), here,

spreadsheet_url, is the url of that spreadsheet the data of which you would like to import. However, if you want, then instead of entire url, you can also just enter workbook key from the link.

Workbook Key for IMPORTRANGE formula

range_string, it’s a string containing information about the range of cells to import. This parameter is made up of two parts : “[sheet_name!]range”

  • sheet name, is the name of spreadsheet from where you are going to import your data.
  • range, this specifically addresses the range of cells, single cell or named cell of that source spreadsheet the data of which will be imported.

This is an optional input to give your specification about the data you want. If it’s not mentioned then the data of whole worksheet will be imported.

How to use IMPORTRANGE Function

The best way to learn anything is through an example and therefore to understand the functioning of IMPORTRANGE function let’s move ahead with an example.

Let’s take a task to import cells A1 to B7 from our source workbook – ‘Employees’. To practice this function follow these steps –

  1. Open the abovementioned workbook i.e., ’employees’.
  2. Now from the location bar of the browser, copy the entire url of workbook or just copy the workbook key.
Google Sheets URL from which you want to fetch the value

3. Now open your workbook and click on the cell from where you want your imported data to start.

4. Type the formula: =IMPORTRANGE(“<<url_here>>”,”<<source_sheet_name_here>>! <<range_here>>”).Replace <<url_here>>, <<source_sheet_name_here>> and <<range_here>> with the appropriate values. In our case, we will enter =IMPORTRANGE(″url of our workbook- employees,”Employees!A1:B7”)

Enter the IMPORTRANGE formula

5. Now press the enter key and wait till it process.

6. In display, you may get something like #REF if using IMPORTAGE function for the first time.

7. While you will hover over the cell, you will get something asking you the permission to access. So here you should select allow access option available.

Allow Access

Now you will get the data of another worksheet imported into your own worksheet.

IMPORTRANGE result

To make the task smooth you should prior ensure that your own spreadsheet has enough data to accommodate the imported data.

And by ensuring this and by following the above-mentioned steps, you will be done with your task.

Harshita Mathur

My name is Harshita Mathur. I come from Jaipur, Rajasthan. I am a law student. Apart from this I am an amateur writer.

Recent Content