OGKit

规则 / og-image-content-type-mismatch · 规则集 2026-07

图片 Content-Type 与实际格式不符

错误og-image-content-type-mismatch
规则 IDog-image-content-type-mismatch
严重程度错误
分类图片
平台全部平台
需要人工处理

这是什么

图片 Content-Type 与实际格式不符。OGKit 规则 og-image-content-type-mismatch(错误)。该 ID 是文档网址与 CI --disable 键使用的公开 API,请勿改名。

以下搜索词应指向本页:

  • Image Content-Type does not match actual format
  • content-type mismatch og:image
  • wrong MIME type image

为什么重要

错误的 Content-Type 或扩展名会让部分抓取器拒绝有效图片。

受影响的平台

全部 OGKit 平台资料,包括使用这些标签的主要社交、聊天与搜索爬虫。

各平台的爬虫预算与字段优先级详见平台行为参考

如何复现

  1. Compare the HTTP Content-Type of the image URL with the actual file signature (magic bytes).
  2. Serving JPEG as image/png (or vice versa) fails this check.

如何修复

以与文件特征一致的 image/jpeg、image/png、image/webp 或 image/gif 提供图片。

没有适用于所有情况的单一模板;请使用 OGKit 问题中的实测值与预期值。