Create a search app Stay organized with collections Save and categorize content based on your preferences.
This page describes how to create a search app.
Create an app
Console
To create a search app using the Google Cloud console, follow these steps:
In the Google Cloud console, go to theAI Applications page.
On theApps page, clickCreate app.
On theCreateapp page, underSite search with AI mode, clickCreate.
Decide if you want Enterprise features for this app and then click thetoggle on or off. Turning on Enterprise edition features is required to get features such aswebsite search and choosing a region for your app. Enterprise editionfeatures incur additional cost. For more information, seeEnterprise edition features.
Decide if you want generative responses with advanced LLM features for thisapp and then click thetoggle on or off. Activating theGenerative Responses option is requiredto get features such assearch summaries orsearch withfollow-ups. For more information, seeGenerative responses.
In theYour app name field, enter a name for your app.
In theExternal name of your company or organization field, enter thecommon name for your company or organization. Avoid suffixes like Inc or LLC.This field helps the LLM identify the company that the app represents.
Select a location for your app. Enterprise features must be turned on topick a location. Google recommends that you use the default,global(Global), unless you have a reason to restrict your data to a particulargeography.
ClickContinue.
To connect to a data store, on theData stores page, select a data storethat you previously created or create a new data store.
Note: If you plan to attach more than one data store to your app, review the capabilities and limitations of doing so inAbout blended search. If you attach only one data store, you can't attach more later.Choose one of the following options:
- Select an existing data store: If you attach only one data store, youcannot remove it or add other data stores to the app later. Attachingmultiple data stores lets you update the attached data stores later, butthe app always requires at least two data stores.
- Create a new data store and ingest data into it:
- ClickCreatedata store and follow the steps in theCreate a new data storepage.
- Choose your new data store and clickSelect. For moreinformation, seeCreate a search data store.
REST
Before you use the command line to create an app, you must have an existing datastore. If you don't have a data store, create one following the steps inCreate a data store and ingest data for Vertex AI Search.
To use theengines.create method to create a search app fromthe command line, follow these steps:
Find your data store ID. If you already have your data storeID, skip to the next step.
In the Google Cloud console, go to theAI Applications page andin the navigation menu, clickData Stores.
Click the name of your data store.
On theData page for your data store, get the data store ID.
Create a search app and connect it to a data store. A data storecan be attached to only one app and can't be removed from the app later.
Key Term: In Vertex AI Search, the termapp can be used interchangeably with the termengine in the context of APIs.curl-XPOST\-H"Authorization: Bearer$(gcloudauthprint-access-token)"\-H"Content-Type: application/json"\-H"X-Goog-User-Project:PROJECT_ID"\"https://discoveryengine.googleapis.com/v1/projects/PROJECT_ID/locations/global/collections/default_collection/engines?engineId=APP_ID"\-d'{ "displayName": "APP_DISPLAY_NAME", "dataStoreIds": ["DATA_STORE_ID"], "solutionType": "SOLUTION_TYPE_SEARCH", "industryVertical": "GENERIC", "searchEngineConfig": { "searchTier": "SEARCH_TIER", "searchAddOns": ["SEARCH_ADD_ON"] }}'Replace the following:
PROJECT_ID: the ID of your Google Cloud project.APP_ID: the ID of the Vertex AI Search app that you want to create.APP_DISPLAY_NAME: the display name of the Vertex AI Search app that you want to create.DATA_STORE_ID: the ID of an existing Vertex AI Search data storethat you want to add to the Vertex AI Search app.SEARCH_TIER: the search tier can beSEARCH_TIER_STANDARDorSEARCH_TIER_ENTERPRISE.SEARCH_TIER_ENTERPRISEis required to get features suchas website search and choosing a region for your app. Enterprise editionfeatures incur additional cost. For more information, seeEnterpriseedition features.SEARCH_ADD_ON: if you want generative responseswith advanced LLM featuresfor this app, then specifySEARCH_ADD_ON_LLM.Generative responses includesearch summaries andsearch with follow-ups.If you don't want generative responses, then either specify
SEARCH_ADD_ON_UNSPECIFIEDas the search add-on or remove thesearchAddOnsfield.For more information, seeGenerative responses.
GENERICis used to create custom search apps that containstructured, unstructured, website data stores, or multiple data stores(blended search).
Python
For more information, see theVertex AI SearchPython API reference documentation.
To authenticate to Vertex AI Search, set up Application Default Credentials. For more information, seeSet up authentication for a local development environment.
fromtypingimportListfromgoogle.api_core.client_optionsimportClientOptionsfromgoogle.cloudimportdiscoveryengine_v1asdiscoveryengine# TODO(developer): Uncomment these variables before running the sample.# project_id = "YOUR_PROJECT_ID"# location = "YOUR_LOCATION" # Values: "global"# engine_id = "YOUR_ENGINE_ID"# data_store_ids = ["YOUR_DATA_STORE_ID"]defcreate_engine_sample(project_id:str,location:str,engine_id:str,data_store_ids:List[str])->str:# For more information, refer to:# https://cloud.google.com/generative-ai-app-builder/docs/locations#specify_a_multi-region_for_your_data_storeclient_options=(ClientOptions(api_endpoint=f"{location}-discoveryengine.googleapis.com")iflocation!="global"elseNone)# Create a clientclient=discoveryengine.EngineServiceClient(client_options=client_options)# The full resource name of the collection# e.g. projects/{project}/locations/{location}/collections/default_collectionparent=client.collection_path(project=project_id,location=location,collection="default_collection",)engine=discoveryengine.Engine(display_name="Test Engine",# Options: GENERIC, MEDIA, HEALTHCARE_FHIRindustry_vertical=discoveryengine.IndustryVertical.GENERIC,# Options: SOLUTION_TYPE_RECOMMENDATION, SOLUTION_TYPE_SEARCH, SOLUTION_TYPE_CHAT, SOLUTION_TYPE_GENERATIVE_CHATsolution_type=discoveryengine.SolutionType.SOLUTION_TYPE_SEARCH,# For search apps onlysearch_engine_config=discoveryengine.Engine.SearchEngineConfig(# Options: SEARCH_TIER_STANDARD, SEARCH_TIER_ENTERPRISEsearch_tier=discoveryengine.SearchTier.SEARCH_TIER_ENTERPRISE,# Options: SEARCH_ADD_ON_LLM, SEARCH_ADD_ON_UNSPECIFIEDsearch_add_ons=[discoveryengine.SearchAddOn.SEARCH_ADD_ON_LLM],),# For generic recommendation apps only# similar_documents_config=discoveryengine.Engine.SimilarDocumentsEngineConfig,data_store_ids=data_store_ids,)request=discoveryengine.CreateEngineRequest(parent=parent,engine=engine,engine_id=engine_id,)# Make the requestoperation=client.create_engine(request=request)print(f"Waiting for operation to complete:{operation.operation.name}")response=operation.result()# After the operation is complete,# get information from operation metadatametadata=discoveryengine.CreateEngineMetadata(operation.metadata)# Handle the responseprint(response)print(metadata)returnoperation.operation.nameTerraform
To learn how to apply or remove a Terraform configuration, seeBasic Terraform commands. For more information, see theTerraform provider reference documentation.
To create a search app using Terraform, seediscovery_engine_search_engine.
What's next
- Get search results.
- Add the search widget to a web page.
- Decide whether you need toset up configurable pricing for your app.
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-02-19 UTC.