Skip to content

最后更新

更新日志

Google Images API

正常只读

来自 images.google.com 的结构化数据。 来源: images.google.com.

基础 URL
https://api.maviapi.com/v1/sites/images-google
3
端点
1 h ago
最近验证
14490ms
p50 延迟
1
自动修复 / 累计
GET/search_images25 credits per call

搜索图片

返回某个查询词的一页 Google Images 结果(约 100 条):每张图片的标题、原图 URL 和尺寸、缩略图、所在网页、来源网站和文件大小。翻到 4-5 页左右就没有更多结果了。

Bearer auth. Pass your key as Authorization: Bearer <key> on every request.
stringOptionalin query

the search text

integerOptionalin query

1-based results page; an empty "results" list means there are no more

stringOptionalin query

any, large, medium or icon

stringOptionalin query

any, photo, clipart, lineart, animated or face

stringOptionalin query

any, color, gray, transparent, or a single colour: red, orange, yellow, green, teal, blue, purple, pink, white, black, brown

stringOptionalin query

how recently the image was published: any, day, week, month or year

stringOptionalin query

any, or creative_commons for images under Creative Commons licences

stringOptionalin query

active to filter explicit results, off to show everything

stringOptionalin query

interface language code, e.g. en, fr, de

stringOptionalin query

two-letter country code of the region to search from, e.g. us, gb, fr

querystringe.g."red fox"
pageintegere.g.1
countintegere.g.100
resultsobject[]13 fields
idstringe.g."w8_Z7HjHAIVjYM"
titlestringe.g."Red Fox Stories | Insights & Photography by Roeselien Raimond"
image_urlstringe.g."https://www.roeselienraimond.com/wp-content/uploads/2025/07/happy-smiling-zen-fox-roeselien-raimond.webp"
widthintegere.g.1000
heightintegere.g.1238
thumbnail_urlstringe.g."https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcTLQ2kP_i1EA_lkUIRQo7t2FbX5pFwOqbq_kZcQ4MqB1g&s=10"
thumbnail_widthintegere.g.498
thumbnail_heightintegere.g.615
page_urlstringe.g."https://www.roeselienraimond.com/species-red-fox/"
domainstringe.g."www.roeselienraimond.com"
site_namestringe.g."Roeselien Raimond"
file_sizestringe.g."169KB"
dominant_colorstringe.g."rgb(104,88,85)"
Try itLive
GET
https://api.maviapi.com/v1/sites/images-google/search_images?q=red%20fox&page=1&size=any&type=any&color=any&time=any&license=any&safe=active&hl=en&gl=us
Request
curl "https://api.maviapi.com/v1/sites/images-google/search_images?q=red%20fox&page=1&size=any&type=any&color=any&time=any&license=any&safe=active&hl=en&gl=us" \
-H "Authorization: Bearer $MAVI_KEY"
Example780 B
{
  "query": "red fox",
  "page": 1,
  "count": 100,
  "results": [
    {
      "id": "w8_Z7HjHAIVjYM",
      "title": "Red Fox Stories | Insights & Photography by Roeselien Raimond",
      "image_url": "https://www.roeselienraimond.com/wp-content/uploads/2025/07/happy-smiling-zen-fox-roeselien-raimond.webp",
      "width": 1000,
      "height": 1238,
      "thumbnail_url": "https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcTLQ2kP_i1EA_lkUIRQo7t2FbX5pFwOqbq_kZcQ4MqB1g&s=10",
      "thumbnail_width": 498,
      "thumbnail_height": 615,
      "page_url": "https://www.roeselienraimond.com/species-red-fox/",
      "domain": "www.roeselienraimond.com",
      "site_name": "Roeselien Raimond",
      "file_size": "169KB",
      "dominant_color": "rgb(104,88,85)"
    }
  ]
}

Get all the data, no code

Collect every page of GET /search_images into a dataset, for one request or for a whole list of them, then download it as CSV or JSON. A page costs the same as one call of the endpoint; the download is free.

Use Google Images API from Claude, ChatGPT and your coding tools

Add this URL as a custom connector and sign in to maviapi. Nothing to install.

How to connect
https://mcp.maviapi.com/mcp

Or run it locally, with each endpoint of Google Images API as its own tool:

claude mcp add maviapi -e MAVIAPI_TOOLS=images-google -- npx -y '@maviapi/mcp'

Import Google Images API into Postman and other tools

How to import

Paste a link into Postman, Insomnia, an agent framework or a no-code tool to get every endpoint with its parameters and response fields. The link always serves the current endpoints, so importing it again picks up new ones.

  • OpenAPI 3.1
    https://api.maviapi.com/v1/apis/images-google/openapi.json
  • Postman
    https://api.maviapi.com/v1/apis/images-google/postman.json

The Postman collection sends the shared demo key until you put your own key in its maviapi_key variable.

使用 Google Images API 进行开发

选择一个端点开始

  • 搜索图片 GET /search_images

    返回某个查询词的一页 Google Images 结果(约 100 条):每张图片的标题、原图 URL 和尺寸、缩略图、所在网页、来源网站和文件大小。翻到 4-5 页左右就没有更多结果了。

    GET /search_images 的参数和响应字段
    请求参数
    名称类型 / 位置必填说明
    qstring / query否the search text
    pageinteger / query否1-based results page; an empty "results" list means there are no more
    sizestring / query否any, large, medium or icon
    typestring / query否any, photo, clipart, lineart, animated or face
    colorstring / query否any, color, gray, transparent, or a single colour: red, orange, yellow, green, teal, blue, purple, pink, white, black, brown
    timestring / query否how recently the image was published: any, day, week, month or year
    licensestring / query否any, or creative_commons for images under Creative Commons licences
    safestring / query否active to filter explicit results, off to show everything
    hlstring / query否interface language code, e.g. en, fr, de
    glstring / query否two-letter country code of the region to search from, e.g. us, gb, fr
    响应字段
    字段类型说明
    querystring
    pageinteger
    countinteger
    resultsobject[]
    results[].idstring
    results[].titlestring
    results[].image_urlstring
    results[].widthinteger
    results[].heightinteger
    results[].thumbnail_urlstring
    results[].thumbnail_widthinteger
    results[].thumbnail_heightinteger
    results[].page_urlstring
    results[].domainstring
    results[].site_namestring
    results[].file_sizestring
    results[].dominant_colorstring
  • 搜索建议 GET /suggestions

    返回 Google Images 针对未输完的图片搜索词给出的自动补全建议,最热门的排在前面。

    GET /suggestions 的参数和响应字段
    请求参数
    名称类型 / 位置必填说明
    qstring / query否the partial search text to complete
    hlstring / query否interface language code, e.g. en, fr, de
    glstring / query否two-letter country code that biases the suggestions, e.g. us, gb, fr
    响应字段
    字段类型说明
    querystring
    suggestionsstring[]
  • 图片 GET /image

    返回某个查询结果中单张图片的完整记录:标题、原图 URL 和尺寸、缩略图、所在网页、来源网站和文件大小。不传 id 时,返回该查询排在第一位的图片。

    GET /image 的参数和响应字段
    请求参数
    名称类型 / 位置必填说明
    idstring / query否the image "id" from search_images results
    qstring / query否the search text the id was found under
    max_pagesinteger / query否how many result pages to look through for the id (1-5)
    响应字段
    字段类型说明
    idstring
    titlestring
    image_urlstring
    widthinteger
    heightinteger
    thumbnail_urlstring
    thumbnail_widthinteger
    thumbnail_heightinteger
    page_urlstring
    domainstring
    site_namestring
    file_sizestring
    dominant_colorstring
    querystring
    pageinteger

将 Google Images 数据导出为 CSV

下面的每个列表都可以下载为 CSV 文件,每条记录一行。用上方控制台下面的 "Get all the data, no code" 卡片把列表收集到数据集中。数据集会逐页读取列表,之后可下载为 CSV、JSON 或 JSONL。

列表CSV 列
搜索图片GET /search_imagesid, title, image_url, width, height, thumbnail_url, thumbnail_width, thumbnail_height, page_url, domain, site_name, file_size, dominant_color

嵌套的值(列表或对象)以 JSON 写入同一个单元格。 数据集和导出如何工作

Google Images API 常见问题

能获取什么数据、费用多少、如何调用。

Google Images 有官方 API 吗?

有,Google Images 提供自己的 API:Custom Search JSON API(核实日期:2026-11-25)。本页的 Google Images API 与它无关,是非官方 API:它是 maviapi 针对 images.google.com 上的公开数据提供的独立托管 API,并非由 Google Images 开发、认可或支持。

Google Images API 可以获取哪些数据?

Google Images API 有 3 个端点。每个端点都返回 JSON,参数和字段见上方的文档:

  • GET /search_images: 返回某个查询词的一页 Google Images 结果(约 100 条):每张图片的标题、原图 URL 和尺寸、缩略图、所在网页、来源网站和文件大小。
  • GET /suggestions: 返回 Google Images 针对未输完的图片搜索词给出的自动补全建议,最热门的排在前面。
  • GET /image: 返回某个查询结果中单张图片的完整记录:标题、原图 URL 和尺寸、缩略图、所在网页、来源网站和文件大小。

Google Images API 的价格是多少?

调用用您 maviapi 套餐中的积分支付,只有成功的调用才会计费。此 API 的每个端点每次调用消耗 25 个积分。在 Hobby 套餐下(每月 $49,含 250,000 个积分),1,000 次调用约 $4.90。失败的调用不收费。Free 套餐每月提供 1,000 个积分,无需信用卡。超出部分请查看套餐和积分价格。

如何调用 Google Images API?

向端点发送 HTTPS 请求,并在 Authorization 请求头中带上您的 API 密钥。例如 GET /search_images:

cURL
curl 'https://api.maviapi.com/v1/sites/images-google/search_images' \
  -H "Authorization: Bearer $MAVI_KEY"

在您的 API 密钥页面创建密钥,或者先在上方的控制台中用免费测试密钥试用任意端点。

以 JSON 获取 Google Images 数据有哪些方式?

以 JSON 获取 Google Images 数据的每种方式适合不同的需求:

  • Custom Search JSON API: 需要写入权限、账号数据或与 Google Images 签订协议时更合适。
  • 自己写爬虫: 完全由自己掌控,不依赖任何服务商,但解析、被拦截的请求以及 images.google.com 每次改版后的修复都要自己负责。更适合从很少变化的页面一次性获取数据。
  • Apify: 一个 Actor 市场,Actor 由您自己运行,输入、输出和价格由各个 Actor 决定。当已有 Actor 能返回您需要的数据,或者您想托管自己的代码时更合适。参见maviapi 与 Apify 的对比。
  • RapidAPI: 一个汇集了众多提供方 API 的平台,用一个 RapidAPI 密钥调用,每个 API 单独定价。当您已经在使用该平台,并且其中某个 API 能满足需求时更合适。来源:RapidAPI docs。
  • maviapi: 本页的 Google Images API:3 个带文档的端点、公开的响应结构,以及一个可用于整个目录的密钥。当这些数据是您产品的一部分,而您不想维护爬虫时更合适。

images.google.com 改版后会怎样?

您的代码不需要改动。images.google.com 修改页面时,maviapi 会让 Google Images API 保持可用,您继续调用同样的端点,并得到本页文档所述结构的 JSON。它当前的运行状况见状态页,变更记录见它的更新日志。

更新会破坏我的 Google Images API 集成吗?

不会。您正在使用的端点,其结构永远不会改变:新的字段、可选参数和端点只会加在旁边,会破坏调用的变更则作为新端点发布。请忽略您不认识的响应字段,新内容请关注更新日志。

  • Google Maps API

    来自 maps.google.com 的结构化数据。

  • Google API

    以 JSON 形式返回 Google 搜索结果:任意查询词的网页排名结果和新闻搜索。

  • Tripadvisor API

    来自 Tripadvisor 的行程规划数据:支持地点搜索,并可按地点(geo_id)获取景点、餐厅和酒店,包含评分、评论、价格和坐标。先用 /search 解析地名,再通过…