TASK_SEARCH is a powerful search function in Sheet Workflows that allows you to perform web searches directly from your Google Sheets. This function leverages the Tavily API to provide comprehensive, reliable search results that can be automatically inserted into your spreadsheet. TASK_SEARCH is ideal for gathering data, researching topics, or collecting information without leaving your spreadsheet environment.
Collecting product information for market research.
Gathering news and current events about specific topics.
Researching companies or organizations.
Finding statistics and data for reports.
Checking facts for content creation.
Discovering relevant resources on a topic.
Monitoring mentions of your brand or products online.
Collecting industry-specific information from trusted sources.
TASK_SEARCH(query, [max_results], [include_headings], [advanced_search_depth], [include_images], [include_domains], [exclude_domains])
Parameter | Data Type | Required | Description |
---|---|---|---|
query |
|
Required | The search term or question you want to find information about. |
max_results |
|
Optional | Maximum number of search results to return. Default is
|
include_headings |
|
Optional | Whether to include column headings in the output. Default is
|
advanced_search_depth |
|
Optional | Whether to use advanced search depth for more comprehensive results. Default is
|
include_images |
|
Optional | Whether to include images in the results. Default is
|
include_domains |
|
Optional | Comma-separated list of websites to include in the search results. |
exclude_domains |
|
Optional | Comma-separated list of websites to exclude from the search results. |
When you set
advanced_search_depth
=TASK_SEARCH("electric vehicle market trends", 10, TRUE, TRUE)
This performs a deeper search about electric vehicle market trends, returning up to 10 results with column headings.
When
include_images
=TASK_SEARCH("landmarks in Paris", 5, TRUE, FALSE, TRUE)
This will return information about Paris landmarks along with related images.
You can focus your search on specific websites using the
include_domains
=TASK_SEARCH("artificial intelligence news", 10, TRUE, FALSE, FALSE, "techcrunch.com,wired.com,theverge.com")
This searches for AI news specifically from TechCrunch, Wired, and The Verge.
Alternatively, you can exclude certain domains from your search:
=TASK_SEARCH("climate change data", 8, TRUE, FALSE, FALSE, "", "pinterest.com,instagram.com")
This searches for climate change data but excludes results from Pinterest and Instagram.
=TASK_SEARCH("healthy breakfast recipes")
This returns 5 search results about healthy breakfast recipes with column headings.
=TASK_SEARCH("renewable energy statistics 2023", 10)
This returns 10 search results about renewable energy statistics from 2023.
=TASK_SEARCH("Tesla financial performance", 7, TRUE, TRUE, FALSE, "bloomberg.com,reuters.com,wsj.com")
This performs an advanced search for Tesla's financial performance from trusted financial news sources.
=TASK_SEARCH("iPhone vs Samsung Galaxy comparison", 8, TRUE, FALSE, TRUE)
This searches for comparisons between iPhone and Samsung Galaxy phones, including images in the results.
Be Specific: The more specific your query, the more relevant your results will be.
Use Domain Filtering: When researching a particular topic, use
include_domains
Limit Results Appropriately: Only request as many results as you need to avoid cluttering your spreadsheet.
Use Advanced Search Depth Sparingly: While more thorough, advanced searches take longer to complete and should be used only when necessary.
Format After Searching: The function will insert plain text, so apply any formatting or data processing after the search results are returned.
Plan Your Spreadsheet Layout: Ensure you have enough empty cells to the right of your function for the results to populate.
Consider Column Headers: If you're using multiple TASK_SEARCH functions, you may want to set
include_headings
Check your Tavily API key in the addon configuration
Verify your internet connection
Try a more general search query
Remove domain restrictions that might be limiting results
Open the Sheet Workflows sidebar
Go to the Configuration section
Look for the Tavily service
Input your API key and save
If you don't have an API key, create a free account at app.tavily.com
Make your query more specific
Use domain filtering to target reliable sources
Increase the search depth by setting
advanced_search_depth
Reduce the number of
max_results
Set
advanced_search_depth
Simplify your query
Remove image inclusion if not necessary
Verify
include_images
Check if your query topic typically has associated images
Some images may not display properly due to source website restrictions
A: Yes, you need to create a free account on app.tavily.com and get an API key.
A: While the function allows you to specify any number, for optimal performance and readability, we recommend limiting to 20 or fewer results.
A: The function primarily searches for text content. While you can include images in the results, it's not designed as an image-only search tool.
A: No, the results are static. If you want updated information, you'll need to run the function again.
A: The results reflect what's available on the web at the time of the search through the Tavily API's index.
A: Yes, you can process the search results with other Google Sheets functions to extract, analyze, or format the data further.
A: Usage limits depend on your Tavily API plan. The free tier typically offers a limited number of searches per month.
A: Yes, you can enter queries in other languages, though the best results are typically returned for English-language searches.
1 month ago