[SOLVED] How did you configure Google Custom Search?

I’m working on the image search project (or rather, about to start it), but I’m stuck with trying to get Google Custom Search to work. The JSON responses I get are not meaningful. How did you configure the custom search? My guess is that the sites to search are incorrect (I just used google.com). I’d appreciate help :slight_smile:

I assume you have got your API key etc.
Go to https://cse.google.com/cse/all and add search engine, then on “Basics” tab set “Image search” to ON, copy from “Details” your “Search Engine ID”.

My request was like this (I split it on multiple lines for this example):


cx=SE_ID&  // Search Engine ID
q=SEARCH_TERM&  // What are you searching for
searchType=image&  // Optional, you set it in settings
start=10  // offset  Optional

Google search free tier has only 50 searches per day, so be frugal :wink:

1 Like

Great, it’s working now! :smiley:

I missed this little option in the “Sites to search” section that says “Search the entire web but emphasize included sites”.

Thanks! :slight_smile: