How to Pull Data from Another Workbook in Google Sheets
Tired of manually copying and pasting data from one Google Sheet to another? There’s a better way. Manually syncing data between spreadsheets isn't just tedious - it's a recipe for errors and outdated information. This tutorial will show you exactly how to pull data from a completely different workbook directly into your Google Sheet, creating a live, automatic link that saves you time and keeps your data accurate.
Why Pull Data From Another Workbook?
Connecting your Google Sheets unlocks a more organized and efficient way to manage your information. Instead of treating each spreadsheet as an isolated island, you can create a network of data that updates automatically. This is especially useful for a few common scenarios:
- Creating a Master Dashboard: You can pull key performance indicators (KPIs) from various departmental sheets (sales, marketing, operations) into a single, high-level dashboard for leadership.
- Consolidating Reports: Imagine you have separate workbooks for regional sales teams (North America, Europe, Asia). You can import the data from each into a global report without anyone having to email their files.
- Maintaining a Single Source of Truth: If you have a master list of products, prices, or employees, you can keep it in one "source" workbook. Other sheets can then pull from this list, ensuring everyone is always using the most up-to-date information.
- Sharing Specific Data: Sometimes you want to share just a summary or a specific data tab with a client or another team, without giving them access to your entire, complex workbook with all its raw data and calculations.
The Easiest Method: The IMPORTRANGE Function
The magic behind connecting separate workbooks is a single, powerful function: IMPORTRANGE. This built-in Google Sheets function is designed specifically to import a range of cells from one spreadsheet into another. It creates a live connection, meaning that when the data in the source sheet changes, your destination sheet updates automatically.
Understanding the IMPORTRANGE Syntax
The formula looks intimidating at first, but it’s actually quite simple. It only has two parts:
=IMPORTRANGE(spreadsheet_url, range_string)
Let's break down each argument:
- spreadsheet_url: This is the full URL of the source spreadsheet you want to pull data from. You just copy it from your browser’s address bar. It must be wrapped in quotation marks. Example: "https://docs.google.com/spreadsheets/d/1aBcD_efGHIjklmnOpqRSTuvWxYzABCdefGHIjk/"
- range_string: This tells Google Sheets which specific cells to import. This is a string that combines the sheet name (or tab name) and the cell range, separated by an exclamation mark. This also needs to be in quotation marks. Format: "SheetName!A1:D50"
Together, the formula tells Google: "Go to this specific URL, find this specific tab, and give me the data in these specific cells."
A Step-by-Step Guide to Using IMPORTRANGE
Ready to try it? Let’s walk through the process of pulling sales data from a regional report into a master sales dashboard.
Step 1: Get the URL of the Source Sheet
Open the Google Sheet that contains the data you want to import (the "source" sheet). Click on your browser's address bar and copy the entire URL. Make sure you get the whole thing.
Step 2: Identify the Data Range in the Source Sheet
Now, still in your source sheet, identify the exact tab and cells you want to grab. Let's say your data is in a tab named "Q1 Sales" and occupies columns A through F, down to row 100. Your range would be A1:F100.
So, the range_string you need for the formula is "Q1 Sales!A1:F100".
Heads up: If your sheet or tab name has spaces or special characters (like "Q1 Sales"), it's required to wrap it in single quotes within your range string, like this: 'Q1 Sales'!A1:F100. To be safe, many users just use single quotes all the time.
Step 3: Write the Formula in Your Destination Sheet
Now, open the sheet where you want the data to appear (the "destination" sheet). Click on the cell where you want the imported data to start (e.g., A1).
Type your formula using the URL and range string you just identified:
=IMPORTRANGE("https://docs.google.com/spreadsheets/d/abc123xyz...", "'Q1 Sales'!A1:F100")
Replace the example URL with your actual URL. After you type it in, press Enter.
Step 4: Allow Access Between the Sheets
The first time you connect two sheets, your formula will return a #REF! error. This is normal!
Hover your mouse over the cell with the error. A blue button will pop up with a message that says, "You need to connect these sheets. Allow access."
Click the "Allow access" button. This is a one-time security step that grants permission for the two workbooks to talk to each other. Once you click it, the #REF! error will disappear, and your data will instantly load into the sheet. You only need to do this once for each pair of workbooks.
Congratulations! You've just created a live link. Any changes a team member makes to the "Q1 Sales" data will now automatically reflect in your master dashboard.
Advanced Tricks: Combining IMPORTRANGE with Other Functions
IMPORTRANGE is powerful on its own, but it becomes truly amazing when you combine it with other functions like QUERY, SORT, and VLOOKUP.
Note: When you combine IMPORTRANGE with another function, you use the entire IMPORTRANGE(...) formula as the input for the "data" or "range" argument of the other function.
Filter Imported Data with QUERY
The QUERY function lets you run database-style queries on your data. This is perfect for when you only want to import specific rows. For instance, you could pull only "Closed-Won" deals from a massive sales pipeline sheet.
When using QUERY with IMPORTRANGE, you have to refer to columns as Col1, Col2, Col3, etc., instead of A, B, C.
Example: Pull only sales from "USA" (which is in the 3rd column, Col3) with a value over $1,000 (in the 6th column, Col6):
=QUERY(IMPORTRANGE("URL...", "SalesData!A1:F100"), "SELECT * WHERE Col3 = 'USA' AND Col6 > 1000")
Sort Imported Data Immediately
Don't want to sort your data after it arrives? Use the SORT function to wrap your IMPORTRANGE and organize it as it's imported.
Example: Import a list of employees and sort it alphabetically by the last name (the 2nd column) in ascending order.
=SORT(IMPORTRANGE("URL...", "Employees!A2:E50"), 2, TRUE)
Enhance Your Data with VLOOKUP
You can use IMPORTRANGE as the lookup table for a VLOOKUP. This is fantastic for pulling in related information from a master sheet without importing the entire thing. For example, you can look up the latest price of a product from a master inventory sheet.
Example: In your sales report, look up the product price from a master "Products!A:C" list stored in another workbook. A2 contains the Product ID to look up.
=VLOOKUP(A2, IMPORTRANGE("URL...", "Products!A:C"), 3, FALSE)
Troubleshooting Common IMPORTRANGE Errors
Things don't always go right on the first try. Here are the most common errors and how to fix them:
- #REF! (Error: "You need to connect these sheets"): You just forgot to click the "Allow access" button after entering the formula for the first time. Hover over the cell and click it.
- #REF! (Error: "Spreadsheet cannot be found"): The URL is wrong. Double-check that you copied and pasted the entire correct URL from the source sheet and that it's in quotation marks.
- #REF! (Error: "Cannot find range or sheet"): The name of your tab or the cell range is incorrect. Check for typos. Is it "Sales Q1" or "Q1 Sales"? Remember that "Sheet1!A:A" is different from "Sheet 1!A:A".
- Security Error: You will see a "#REF!" error if you don't have at least "View" permission on the source sheet. You can't pull data from a sheet you don't have access to. Ask the owner of the sheet to share it with you.
Pro-Tips for Clean and Scalable Workbooks
As you use IMPORTRANGE more, a couple of best practices will save you future headaches.
1. Import Raw Data to a Dedicated Tab
Never write your IMPORTRANGE formula on the same tab where you'll be doing a lot of analysis or adding your own data. Instead, create a new tab called something like "Raw Import - Sales." Place your single IMPORTRANGE formula in cell A1 of that tab. Then, on your other tabs, reference the data from this "Raw Import" tab. This keeps the live data source separate from your analysis, preventing accidental overwrites and making your formulas much easier to manage.
2. Use Named Ranges in Your Source Sheet
Instead of hard-coding "Sheet1!A2:F100" into your formula, you can name that range in the source sheet (by going to Data > Named ranges). If you name the range "Q1SalesData," your formula becomes:
=IMPORTRANGE("URL...", "Q1SalesData")
This is much more readable and won't break if someone inserts new rows or columns in the source sheet.
Final Thoughts
Mastering IMPORTRANGE lets you build sophisticated, interconnected reporting systems right within Google Sheets. You can stop the endless cycle of copy-pasting and start trusting that your numbers are always synchronized, allowing you to focus on analysis instead of data wrangling.
While connecting workbooks in Google Sheets is an excellent first step, a lot more manual work remains when reporting across other applications. At Graphed, we automate the entire process by connecting directly to all your data sources — like Google Analytics, Shopify, Facebook Ads, and Salesforce — in minutes. Instead of building formulas, you use plain English to instantly create real-time dashboards and ask questions about your performance, uniting all your business info effortlessly.
Related Articles
What SEO Tools Work with Google Analytics?
Discover which SEO tools integrate seamlessly with Google Analytics to provide a comprehensive view of your site's performance. Optimize your SEO strategy now!
Looker Studio vs Metabase: Which BI Tool Actually Fits Your Team?
Looker Studio and Metabase both help you turn raw data into dashboards, but they take completely different approaches. This guide breaks down where each tool fits, what they are good at, and which one matches your actual workflow.
How to Create a Photo Album in Meta Business Suite
How to create a photo album in Meta Business Suite — step-by-step guide to organizing Facebook and Instagram photos into albums for your business page.