影片 (VideoObjectClipBroadcastEvent) 結構化資料

Google 搜尋是使用者探索及觀看影片的起始點。雖然 Google 會嘗試自行理解您影片的相關詳細資料,您仍可透過 VideoObject 明確提供說明、縮圖網址、上傳日期和時間長度等詳細資訊。Google 搜尋結果、影片搜尋結果、Google 圖片以及 Google 探索中都有可能顯示影片內容。

顯示 Google 搜尋結果、影片分頁和「探索」專區中的影片內容螢幕截圖

依您標記內容的方式而定,您的影片可能也適用下列影片強化功能:

影片強化功能

「直播」標記:為影片加上 BroadcastEvent 標記,即可讓影片顯示「直播」標記。「直播」標記適用於任何長度的公開直播影片,例如:

  • 體育賽事
  • 頒獎典禮
  • 網紅影片
  • 電玩遊戲直播

請務必遵守「直播」標記規範,並使用 Indexing API 確保 Google 在正確的時機檢索您的網頁。

搜尋結果中一部具有「直播」標記的影片

居家活動:協助使用者尋找在家就能從事的活動。當使用者搜尋能在家中進行的活動時,您的影片和線上活動就能呈現為更加生動的複合式搜尋結果。如果您的線上活動已加入 Video 結構化資料,那麼無須進行更多操作,就可能以這項複合式搜尋結果的形式呈現。

如要進一步瞭解功能的適用情況、指南規範與範例,請參閱「居家活動」一文。

搜尋結果中的居家活動

重要時刻

「重要時刻」功能可將影片像書籍章節一樣分段,不但方便使用者瀏覽,更能吸引他們進一步與您的內容互動。您不必採取任何行動,Google 搜尋就會自動嘗試偵測影片中的片段,並向使用者顯示重要時刻。或者,您也可以自行告知 Google 影片的重點段落為何:我們會優先採用您透過結構化資料或 YouTube 說明設定的重要時刻。

  • 如果您的影片由自己的網頁代管,可以透過下列兩種方式啟用重要時刻功能:
    • Clip 結構化資料:指定每個片段確切的開始和結束時間,以及要顯示的片段標籤。所有支援 Google 搜尋的語言都支援這項功能。
    • SeekToAction 結構化資料:告訴 Google 時間戳記通常位於您網址結構中的哪個位置,讓 Google 自動識別重要時刻,並將使用者直接連結至影片中的段落。 這項功能目前支援下列語言:英文、西班牙文、葡萄牙文、義大利文、中文、法文、日文、德文、土耳其文、韓文、荷蘭文和俄文。我們預計日後將支援更多語言。即使是使用支援的語言,系統也不是都會辨識出所有影片的重要時刻,不過我們會不斷努力改善。
  • 如果您的影片由 YouTube 代管,可以在 YouTube 的影片說明中指定確切的時間戳記和標籤。請參閱在 YouTube 說明中標示時間戳記的最佳做法。所有支援 Google 搜尋的語言都支援這項功能。

    如果想在 YouTube 上啟用影片章節功能,請額外遵循其他規範

如要徹底停用重要時刻功能 (包括 Google 為了自動顯示影片的重要時刻而執行的所有操作),請使用 nosnippet meta 標記。

搜尋結果中含有重要時刻的影片
影片代管網頁輪轉介面 (有使用限制):透過新增 ItemList 結構化資料,讓使用者探索您的影片庫網頁。這項功能目前僅提供少數供應商使用。您可能無須新增 ItemList 結構化資料,Google 搜尋就會自動為您的網站顯示代管網頁輪轉介面。

教學影片:透過新增教學影片結構化資料,協助學生和老師找到您的教育影片。如要進一步瞭解功能的適用情況、指南規範與範例,請參閱教學影片說明文件

搜尋結果中的教學影片

如何新增結構化資料

結構化資料是一種標準化格式,能夠提供網頁相關資訊並分類網頁內容。如果您是第一次使用結構化資料,請參閱這篇文章,進一步瞭解結構化資料的運作方式。

以下簡要說明如何建立、測試及發布結構化資料。

  1. 新增必要屬性。根據您使用的格式,瞭解要在網頁中的什麼位置插入結構化資料
  2. 遵循指南規範
  3. 使用複合式搜尋結果測試驗證程式碼,並修正所有重大錯誤。此外,我們也建議您修正工具中可能標記的任何非重大問題,因為這有助於改善結構化資料的品質 (但並非符合複合式搜尋結果的顯示條件)。
  4. 部署幾個包含結構化資料的網頁,並使用網址檢查工具測試 Google 轉譯網頁的情形。請確認 Google 可以存取您的網頁,且網頁並未遭到 robots.txt 檔案或 noindex 標記封鎖,也未設有登入規定。如果網頁看起來沒問題,您可以要求 Google 重新檢索您的網址
  5. 為了讓 Google 掌握日後的異動內容,建議您提交 Sitemap。您可以使用 Search Console Sitemap API 自動執行這項操作。

範例

標準影片複合式搜尋結果

標準影片搜尋結果範例

以下是採用單一 VideoObject 的範例。

JSON-LD

<html>
  <head>
    <title>Introducing the self-driving bicycle in the Netherlands</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org",
      "@type": "VideoObject",
      "name": "Introducing the self-driving bicycle in the Netherlands",
      "description": "This spring, Google is introducing the self-driving bicycle in Amsterdam, the world's premier cycling city. The Dutch cycle more than any other nation in the world, almost 900 kilometres per year per person, amounting to over 15 billion kilometres annually. The self-driving bicycle enables safe navigation through the city for Amsterdam residents, and furthers Google's ambition to improve urban mobility with technology. Google Netherlands takes enormous pride in the fact that a Dutch team worked on this innovation that will have great impact in their home country.",
      "thumbnailUrl": [
        "https://example.com/photos/1x1/photo.jpg",
        "https://example.com/photos/4x3/photo.jpg",
        "https://example.com/photos/16x9/photo.jpg"
       ],
      "uploadDate": "2016-03-31T08:00:00+08:00",
      "duration": "PT1M54S",
      "contentUrl": "https://www.example.com/video/123/file.mp4",
      "embedUrl": "https://www.example.com/embed/123",
      "interactionStatistic": {
        "@type": "InteractionCounter",
        "interactionType": { "@type": "WatchAction" },
        "userInteractionCount": 5647018
      },
      "regionsAllowed": "US,NL"
    }
    </script>
  </head>
  <body>
  </body>
</html>
微資料

<html itemscope itemprop="VideoObject" itemtype="https://schema.org/VideoObject">
<head>
  <title itemprop="name">Introducing the self-driving bicycle in the Netherlands</title>
</head>
<body>
  <meta itemprop="uploadDate" content="2016-03-31T08:00:00+08:00" />
  <meta itemprop="duration" content="PT1M54S" />
  <p itemprop="description">This spring, Google is introducing the self-driving bicycle in Amsterdam, the world's premier cycling city. The Dutch cycle more than any other nation in the world, almost 900 kilometres per year per person, amounting to over 15 billion kilometres annually. The self-driving bicycle enables safe navigation through the city for Amsterdam residents, and furthers Google's ambition to improve urban mobility with technology. Google Netherlands takes enormous pride in the fact that a Dutch team worked on this innovation that will have great impact in their home country.</p>
  <div itemprop="interactionStatistic" itemtype="https://schema.org/InteractionCounter" itemscope>
    <meta itemprop="userInteractionCount" content="5647018" />
    <meta itemprop="interactionType" itemtype="https://schema.org/WatchAction" />
  </div>
  <link itemprop="embedUrl" href="https://www.example.com/embed/123" />
  <meta itemprop="contentUrl" content="https://www.example.com/video/123/file.mp4" />
  <meta itemprop="regionsAllowed" content="US,NL" />
  <meta itemprop="thumbnailUrl" content="https://example.com/photos/1x1/photo.jpg" />
</body>
</html>

直播標記

搜尋結果中包含「直播」標記的影片範例

以下是 VideoObjectBroadcastEvent 的範例。

JSON-LD

<html>
  <head>
    <title>Bald Eagle at the Park - Livestream</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org",
      "@type": "VideoObject",
      "contentURL": "https://example.com/bald-eagle-at-the-park.mp4",
      "description": "Bald eagle at the park livestream.",
      "duration": "PT37M14S",
      "embedUrl": "https://example.com/bald-eagle-at-the-park",
      "expires": "2018-10-30T14:37:14+00:00",
      "regionsAllowed": "US",
      "interactionStatistic": {
        "@type": "InteractionCounter",
        "interactionType": { "@type": "WatchAction" },
        "userInteractionCount": 4756
      },
      "name": "Bald eagle nest livestream!",
      "thumbnailUrl": "https://example.com/bald-eagle-at-the-park",
      "uploadDate": "2018-10-27T14:00:00+00:00",
      "publication": [
        {
          "@type": "BroadcastEvent",
          "isLiveBroadcast": true,
          "startDate": "2018-10-27T14:00:00+00:00",
          "endDate": "2018-10-27T14:37:14+00:00"
        },
        {
          "@type": "BroadcastEvent",
          "isLiveBroadcast": true,
          "startDate": "2018-10-27T18:00:00+00:00",
          "endDate": "2018-10-27T18:37:14+00:00"
        }
      ]
    }
    </script>
  </head>
  <body>
  </body>
</html>
微資料

<html itemscope itemprop="VideoObject" itemtype="https://schema.org/VideoObject">
<head>
  <title itemprop="name">Bald Eagle at the Park - Livestream</title>
</head>
<body>
  <meta itemprop="uploadDate" content="2018-10-27T14:00:00+00:00" />
  <meta itemprop="duration" content="PT37M14S" />
  <p itemprop="description">Bald eagle at the park livestream.</p>
  <div itemprop="interactionStatistic" itemtype="https://schema.org/InteractionCounter" itemscope>
    <meta itemprop="userInteractionCount" content="4756" />
    <meta itemprop="interactionType" itemtype="https://schema.org/WatchAction" />
  </div>
  <link itemprop="embedUrl" href="https://example.com/bald-eagle-at-the-park" />
  <meta itemprop="expires" content="2018-10-30T14:37:14+00:00" />
  <meta itemprop="contentUrl" content="https://example.com/bald-eagle-at-the-park.mp4" />
  <meta itemprop="regionsAllowed" content="US" />
  <meta itemprop="thumbnailUrl" content="https://example.com/bald-eagle-at-the-park" />
  <div itemprop="publication" itemtype="https://schema.org/BroadcastEvent" itemscope>
    <meta itemprop="isLiveBroadcast" content="true" />
    <meta itemprop="startDate" content="2018-10-27T14:00:00+00:00" />
    <meta itemprop="endDate" content="2018-10-27T14:37:14+00:00" />
  </div>
  <div itemprop="publication" itemtype="https://schema.org/BroadcastEvent" itemscope>
    <meta itemprop="isLiveBroadcast" content="true" />
    <meta itemprop="startDate" content="2018-10-27T18:00:00+00:00" />
    <meta itemprop="endDate" content="2018-10-27T18:37:14+00:00" />
  </div>
</body>
</html>

以下是 VideoObjectItemList 結構化資料的範例。這項功能目前僅提供少數供應商使用。

JSON-LD

<html>
  <head>
    <title>Introducing the self-driving bicycle in the Netherlands</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org",
      "@type": "ItemList",
      "itemListElement": [
        {
          "@type": "VideoObject",
          "position": 1,
          "name": "Introducing the self-driving bicycle in the Netherlands",
          "url": "https://www.example.com/video/self-driving-bicycle",
          "description": "This spring, Google is introducing the self-driving bicycle in Amsterdam, the world's premier cycling city. The Dutch cycle more than any other nation in the world, almost 900 kilometres per year per person, amounting to over 15 billion kilometres annually. The self-driving bicycle enables safe navigation through the city for Amsterdam residents, and furthers Google's ambition to improve urban mobility with technology. Google Netherlands takes enormous pride in the fact that a Dutch team worked on this innovation that will have great impact in their home country.",
          "thumbnailUrl": [
            "https://www.example.com/video/self-driving-bicycle/1x1/photo.jpg",
            "https://www.example.com/video/self-driving-bicycle/4x3/photo.jpg",
            "https://www.example.com/video/self-driving-bicycle/16x9/photo.jpg"
          ],
          "uploadDate": "2016-03-31T08:00:00+08:00",
          "duration": "PT1M54S",
          "contentUrl": "https://www.example.com/video/self-driving-bicycle/file.mp4",
          "embedUrl": "https://www.example.com/embed/self-driving-bicycle",
          "interactionStatistic": {
            "@type": "InteractionCounter",
            "interactionType": { "@type": "WatchAction" },
            "userInteractionCount": 5647018
          }
        },
        {
          "@type": "VideoObject",
          "position": 2,
          "name": "How to tie a tie",
          "url": "https://www.example.com/video/how-to-tie-a-tie",
          "description": "How to tie a four-in-hand knot.",
          "thumbnailUrl": [
            "https://www.example.com/video/how-to-tie-a-tie/1x1/photo.jpg",
            "https://www.example.com/video/how-to-tie-a-tie/4x3/photo.jpg",
            "https://www.example.com/video/how-to-tie-a-tie/16x9/photo.jpg"
          ],
          "uploadDate": "2019-02-28T08:00:00+08:00",
          "duration": "PT5M01S",
          "contentUrl": "https://www.example.com/video/how-to-tie-a-tie/file.mp4",
          "embedUrl": "https://www.example.com/embed/how-to-tie-a-tie",
          "interactionStatistic": {
            "@type": "InteractionCounter",
            "interactionType": { "@type": "WatchAction" },
            "userInteractionCount": 102111
          }
        }
      ]
    }
    </script>
  </head>
  <body>
  </body>
</html>
微資料

<div>
      <div itemprop="video" itemscope itemtype="https://schema.org/VideoObject">
        <!-- Thumbnail -->
        <a href="https://example.com/videos/self-driving-bicycle"
           title="Introducing the self-driving bicycle in the Netherlands">
          <img src="https://example.com/videos/self-driving-bicycle/thumbnail.jpg"
               alt="Introducing the self-driving bicycle in the Netherlands"
               title="Introducing the self-driving bicycle in the Netherlands"
               itemprop="thumbnailUrl">
        </a>
        <!-- URL, name, and description -->
        <h1>
          <a itemprop="contentUrl" href="https://example.com/videos/self-driving-bicycle"
             title="Introducing the self-driving bicycle in the Netherlands">
            <span itemprop="name">Introducing the self-driving bicycle in the Netherlands</span>
          </a>
        </h1>
        <a href="https://example.com/videos/self-driving-bicycle"
             title="Introducing the self-driving bicycle in the Netherlands">
          <div itemprop="description">"This spring, Google is introducing the self-driving bicycle
            in Amsterdam, the world's premier cycling city. The Dutch cycle more than any other
            nation in the world, almost 900 kilometres per year per person, amounting to over 15
            billion kilometres annually. The self-driving bicycle enables safe navigation through
            the city for Amsterdam residents, and furthers Google's ambition to improve urban
            mobility with technology. Google Netherlands takes enormous pride in the fact that a
            Dutch team worked on this innovation that will have great impact in their home country.
          "</div>
        </a>
        <!-- Other metadata -->
        <meta itemprop="duration" content="PT1M54S" />
        <meta itemprop="uploadDate" content="2016-03-31T08:00:00+08:00" />
        <span itemprop="interactionStatistic" itemscope itemtype="https://schema.org/InteractionCounter">
        	<span itemprop="interactionType" itemscope itemtype="https://schema.org/WatchAction"></span>
        	<meta itemprop="userInteractionCount" content="5647018" />
        </span>
      </div>

      <div itemprop="video" itemscope itemtype="https://schema.org/VideoObject">
        <!-- Thumbnail -->
        <a href="https://example.com/videos/how-to-tie-a-tie"
           title="How to tie a tie">
          <img src="https://example.com/videos/how-to-tie-a-tie/thumbnail.jpg"
               alt="How to tie a tie"
               title="How to tie a tie"
               itemprop="thumbnailUrl">
        </a>
        <!-- URL, name, and description -->
        <h1>
          <a itemprop="contentUrl" href="https://example.com/videos/how-to-tie-a-tie"
             title="Tie a Tie">
            <span itemprop="name">Tie a Tie</span>
          </a>
        </h1>
        <a href="https://example.com/videos/how-to-tie-a-tie"
             title="Tie a Tie">
          <div itemprop="description">How to tie a four-in-hand knot.</div>
        </a>
        <!-- Other metadata -->
        <meta itemprop="duration" content="PT5M01S" />
        <meta itemprop="uploadDate" content="2019-01-05T08:00:00+08:00" />
        <span itemprop="interactionStatistic" itemscope itemtype="https://schema.org/InteractionCounter">
        	<span itemprop="interactionType" itemscope itemtype="https://schema.org/WatchAction"></span>
        	<meta itemprop="userInteractionCount" content="102111" />
        </span>
      </div>
    </div>
  

Clip

搜尋結果中含有重要時刻的影片範例

以下是 VideoObjectClip 的範例。

JSON-LD

<html>
  <head>
    <title>Cat jumps over the fence</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org/",
      "@type": "VideoObject",
      "name": "Cat video",
      "duration": "PT10M",
      "uploadDate": "2019-07-19T08:00:00+08:00",
      "thumbnailUrl": "https://www.example.com/cat.jpg",
      "description": "Watch this cat jump over a fence!",
      "contentUrl": "https://www.example.com/cat_video_full.mp4",
      "regionsAllowed": "US",
      "hasPart": [{
        "@type": "Clip",
        "name": "Cat jumps",
        "startOffset": 30,
        "endOffset": 45,
        "url": "https://www.example.com/example?t=30"
      },
      {
        "@type": "Clip",
        "name": "Cat misses the fence",
        "startOffset": 111,
        "endOffset": 150,
        "url": "https://www.example.com/example?t=111"
      }]
    }
    </script>
  </head>
  <body>
  </body>
</html>
微資料

<html itemscope itemprop="VideoObject" itemtype="https://schema.org/VideoObject">
<head>
  <title itemprop="name">Cat jumps over the fence</title>
</head>
<body>
  <meta itemprop="uploadDate" content="2019-07-19" />
  <meta itemprop="duration" content="P10M" />
  <p itemprop="description">Watch this cat jump over a fence!</p>
  <div itemprop="interactionStatistic" itemtype="https://schema.org/InteractionCounter" itemscope>
    <meta itemprop="userInteractionCount" content="5647018" />
    <meta itemprop="interactionType" itemtype="https://schema.org/WatchAction" />
  </div>
  <div itemprop="hasPart" itemtype="https://schema.org/Clip" itemscope>
    <meta itemprop="name" content="Cat jumps" />
    <meta itemprop="startOffset" content="30" />
    <meta itemprop="endOffset" content="45" />
    <meta itemprop="url" content="https://www.example.com/example?t=30" />
  </div>
  <div itemprop="hasPart" itemtype="https://schema.org/Clip" itemscope>
    <meta itemprop="name" content="Cat misses the fence" />
    <meta itemprop="startOffset" content="111" />
    <meta itemprop="endOffset" content="150" />
    <meta itemprop="url" content="https://www.example.com/example?t=111" />
  </div>
  <link itemprop="embedUrl" href="https://www.example.com/embed/123" />
  <meta itemprop="contentUrl" content="https://www.example.com/cat_video_full.mp4" />
  <meta itemprop="regionsAllowed" content="US" />
  <meta itemprop="thumbnailUrl" content="https://www.example.com/cat.jpg" />
</body>
</html>

SeekToAction

以下是採用單一 VideoObject 的範例,其中包含 SeekToAction 標記所需的額外屬性

JSON-LD

<html>
  <head>
    <title>John Smith (@johnsmith123) on VideoApp: My daily workout! #stayingfit</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org",
      "@type": "VideoObject",
      "potentialAction" : {
        "@type": "SeekToAction",
        "target": "https://video.example.com/watch/videoID?t={seek_to_second_number}",
        "startOffset-input": "required name=seek_to_second_number"
      },
      "name": "My daily workout!",
      "uploadDate": "2020-07-19T08:00:00+08:00",
      "thumbnailUrl": "https://www.example.com/daily-workout.jpg",
      "description": "My daily workout!",
      "embedUrl": "https://example.com/daily-workout"
    }
    </script>
  </head>
  <body>
  </body>
</html>
微資料

<html itemscope itemprop="VideoObject" itemtype="https://schema.org/VideoObject">
<head>
  <title itemprop="name">John Smith (@johnsmith123) on VideoApp: My daily workout! #stayingfit</title>
</head>
<body>
  <meta itemprop="uploadDate" content="2020-07-19" />
  <p itemprop="description">My daily workout!</p>
  <div itemprop="potentialAction" itemtype="https://schema.org/SeekToAction" itemscope>
    <meta itemprop="target" content="https://video.example.com/watch/videoID?t={seek_to_second_number}" />
    <meta itemprop="startOffset-input" content="required name=seek_to_second_number" />
  </div>
  <link itemprop="embedUrl" href="https://example.com/daily-workout" />
  <meta itemprop="thumbnailUrl" content="https://www.example.com/daily-workout.jpg" />
</body>
</html>

指南

如要讓網頁顯示影片複合式搜尋結果,請務必遵守搜尋基礎入門一般結構化資料指南影片最佳做法

此外,如果您的影片內容適用於以下指南,建議您詳細參閱:

「直播」標記規範

如果要為直播影片新增 BroadcastEvent,請遵守下列規範:

  • 請勿在結構化資料中使用粗俗或可能令人反感的用語。
  • 請使用 Indexing API,以確保 Google 在正確的時機檢索您的直播影片。請在下列情況下呼叫 API:
    • 當影片開始直播時
    • 當影片已停止串流,且網頁標記已更新為表示 endDate
    • 當標記有所異動,且有必要通知 Google 時

在 YouTube 中標示時間戳記的最佳做法

如果您的影片是由 YouTube 代管,Google 搜尋可能會根據 YouTube 上的影片說明自動為您的影片啟用重要時刻功能,無須您親自在 YouTube 說明中標示特定的時間戳記。不過,您可以明確告知我們您影片中的重點段落,Google 會偏好採用您所提供的資訊。下圖說明 YouTube 影片說明中的時間戳記和標籤,可能會如何顯示在搜尋結果中:

搜尋結果中含有時間戳記和標籤的影片
1. 標籤:剪輯名稱。
2.時間戳記:剪輯開始的時間。

為 YouTube 影片說明標示時間戳記和標籤時,請遵循下列指南規範:

  • 採用下列格式設定時間戳記:[hour]:[minute]:[second]。如果沒有小時這個單位,則不必包含在格式中。
  • 在時間戳記的同一行指定時間戳記標籤。
  • 在影片說明中的每一行列出一個時間戳記。
  • 將時間戳記連結至影片中指定的時間點。
  • 確認標籤包含至少一個字詞。
  • 依時間順序列出時間戳記。

如果想在 YouTube 上啟用影片章節功能,請額外遵循其他規範

ClipSeekToAction 指南

如要新增 ClipSeekToAction 結構化資料來標記影片片段,請遵守以下規範:

  • 影片必須具備深層連結,可將使用者導向網址所指定影片開始時間點之外的特定時間點。舉例來說,https://www.example.com/example?t=30 可跳至影片播放 30 秒後的畫面。
  • 您必須在使用者能夠觀看影片的頁面中新增 VideoObject 結構化資料。如果將使用者導向無法觀看影片的網頁,可能會導致使用者體驗不佳。
  • 影片總長度必須至少為 30 秒。
  • 影片必須包含 VideoObject 結構化資料說明文件列出的必要屬性。
  • 針對 Clip 結構化資料:請確定在相同頁面中定義的同一部影片,沒有開始時間重複的剪輯片段。
  • 針對 SeekToAction 結構化資料:Google 必須能夠擷取您的影片內容檔案

結構化資料類型定義

本節說明與 Google 搜尋中影片功能相關的結構化資料類型。 您的內容必須包含必要的 VideoObject 屬性,才能以複合式搜尋結果的形式呈現。您也可以加入建議的屬性,為 VideoObject 增添更多相關資訊,提供更優質的使用者體驗。除了 VideoObject 之外,您還可以新增下列資料類型,以便在 Google 搜尋中啟用影片強化功能:

  • BroadcastEvent:標記直播影片,為您的影片啟用「直播」標記。
  • ItemList:標記含有影片清單的網頁,以啟用影片代管網頁輪轉介面。
  • Clip:手動標記影片中的重要片段,協助使用者快速前往影片中的特定時間點。
  • SeekToAction:透過指出網址的結構來啟用重要時刻,讓 Google 可以自動識別影片中的重要時刻,並將使用者連結至這些重要時刻在影片中的時間點。
  • 教學影片:透過新增教學影片結構化資料,協助學生和老師找到您的教育影片。

VideoObject

schema.org/VideoObject 內提供 VideoObject 的完整定義。如果您未提供必要屬性,Google 可能無法擷取任何影片相關資訊。您也可以加入建議的屬性,為內容增添更多相關資訊,提供更優質的使用者體驗。

必要屬性
name

Text

影片的標題

thumbnailUrl

重複的 URL

指向影片縮圖檔案的網址。請遵守縮圖圖片規範

uploadDate

DateTime

影片首次發布的日期和時間,採 ISO 8601 格式。建議您提供時區資訊。否則,系統會預設為 Googlebot 使用的時區

建議屬性
contentUrl

URL

指向實際影片媒體檔案的網址,採用其中一種支援的編碼格式。請勿連結至影片所在的網頁,這必須是影片媒體檔案本身的網址。

"contentUrl": "https://www.example.com/video/123/file.mp4"

請務必遵循我們的影片最佳做法

description

Text

影片的說明。系統會忽略 HTML 標記。

duration

Duration

影片的長度,採 ISO 8601 格式。 例如 PT00H30M5S 表示影片長度為「三十分鐘五秒」。

embedUrl

URL

這個網址會將特定影片指向播放器。請勿連結至影片所在的網頁,這必須是影片播放器本身的網址。一般來說,這是 <embed> 標記中 src 屬性的資訊。

"embedUrl": "https://www.example.com/embed/123"

請務必遵循我們的影片最佳做法

expires DateTime

(如適用) 影片到期的日期和時間 (採用 ISO 8601 格式)。如果您的影片並無期限,請不要提供這項資訊。建議您提供時區資訊。否則,系統會預設為 Googlebot 使用的時區

hasPart

如果您的影片含有重要片段,請在 VideoObject 中建立必要 Clip 屬性的巢狀結構。例如:

<script type="application/ld+json">
{
  "@context": "https://schema.org/",
  "@type": "VideoObject",
  "name": "Cat video",
  "hasPart": {
    "@type": "Clip",
    "name": "Cat jumps",
    "startOffset": 30,
    "url": "https://www.example.com/example?t=30"
  }
}
</script>
interactionStatistic

InteractionCounter

影片的觀看次數。例如:

"interactionStatistic":
  {
    "@type": "InteractionCounter",
    "interactionType": { "@type": "WatchAction" },
    "userInteractionCount": 12345
  }
publication

如要直播影片,您必須在 VideoObject 中建立 BroadcastEvent 屬性的巢狀結構,才能讓影片顯示「直播」標記。例如:

<script type="application/ld+json">
{
  "@context": "https://schema.org/",
  "@type": "VideoObject",
  "name": "Cat video",
  "publication": {
    "@type": "BroadcastEvent",
    "name": "First scheduled broadcast",
    "isLiveBroadcast": true,
    "startDate": "2018-10-27T14:00:00+00:00",
    "endDate": "2018-10-27T14:37:14+00:00"
  }
}
</script>
regionsAllowed

Place

允許瀏覽這部影片的地區。如果未指定,Google 會假設任何地方的使用者都可以瀏覽這部影片。請採用 ISO 3166 格式來指定國家/地區。如有多個值,請使用空格或半形逗號隔開。

BroadcastEvent

您必須在 VideoObject 中建立下列屬性的巢狀結構,才能讓您的影片顯示「直播」標記。雖然 BroadcastEvent 並非必要屬性,但如果您想讓自己的影片顯示「直播」標記,就必須新增下列屬性。

schema.org/BroadcastEvent 內提供 BroadcastEvent 的完整定義。

必要屬性
publication

BroadcastEvent

說明影片直播時間,可為清單或單一例項。

publication.endDate

DateTime

直播結束或預計結束的日期和時間,採 ISO 8601 格式

影片結束並停止直播後,就必須提供 endDate。如果在直播開始前還不知道預計的 endDate,建議您提供概略的 endDate

如果 endDate 是過去或現在的時間,表示串流實際上已結束並已停止直播。如果 endDate 是未來的時間,表示串流預計在該時間結束。

publication.isLiveBroadcast

布林值

如果影片正在直播、已直播過或將會直播,請設為 true

publication.startDate

DateTime

直播開始或預計開始的日期和時間,採 ISO 8601 格式。如果 startDate 是過去或現在的時間,表示串流實際上已開始。如果 startDate 是未來的時間,表示串流預計在該時間開始。

ItemList (有使用限制)

為了讓 Google 更瞭解您的影片庫網頁,除了 VideoObject 屬性之外,請再加入下列 ItemList 屬性。如要進一步瞭解輪轉介面,請參閱「輪轉介面」。

schema.org/ItemList 內提供 ItemList 的完整定義。

必要屬性
itemListElement

ListItem

單一項目頁面的註解。每個 ListItem 元素都必須包含 VideoObject 屬性ListItem 屬性。

ListItem.position

Integer

項目頁面在清單中的序數位置。例如:

"itemListElement": [
  {
    "@type": "VideoObject",
    "position": 1,
    ... other VideoObject properties ...
  }, {
    "@type": "VideoObject",
    "position": 2,
    ... other VideoObject properties ...
  }
]
ListItem.url

URL

項目頁面的標準網址。每個項目都必須有一個專屬網址。

Clip

如要手動通知 Google 要在重要時刻功能中使用的時間戳記和標籤,請在 VideoObject 中建立下列屬性的巢狀結構。雖然 Clip 並非必要屬性,但如果想讓 Google 顯示您為影片指定的時間戳記和標籤 (而非 Google 自動顯示的影片片段),則必須新增下列屬性。

schema.org/Clip 內提供 Clip 的完整定義。

必要屬性
name

Text

剪輯內容的描述性標題。

startOffset

Number

剪輯開始時間 (以影片開頭算起的秒數表示)。

url

URL

指向剪輯開始時間的網址。

剪輯網址必須指向與影片相同的網址路徑,並附上指定時間的其他查詢參數。

舉例來說,下列網址表示影片的開始時間為 2:00 分:

"url": "https://www.example.com/example?t=120"
建議屬性
endOffset

Number

剪輯結束時間 (以影片開頭算起的秒數表示)。

SeekToAction

如要將網址結構告知 Google,讓 Google 能顯示自動辨識的影片重要片段,請在 VideoObject 中建立下列巢狀屬性。雖然 SeekToAction 並非必要屬性,但如果想讓 Google 瞭解您的網址結構,就必須新增下列屬性,這樣 Google 才能將使用者連結至影片中的特定時間點。

schema.org/SeekToAction 內提供 SeekToAction 的完整定義。

必要屬性
potentialAction

SeekToAction

指定一個可能的動作。請加入下列巢狀屬性:

例如:

{
  "@context": "https://schema.org",
  "@type": "VideoObject",
  "potentialAction" : {
    "@type": "SeekToAction",
    "target": "https://video.example.com/watch/videoID?t={seek_to_second_number}",
    "startOffset-input": "required name=seek_to_second_number"
  }
)
potentialAction.startOffset-input

Text

Google 會將這個預留位置字串視為時間戳記結構,然後替換成要略過的秒數。請使用下列的值:

"startOffset-input": "required name=seek_to_second_number"

startOffset-input 是加註的屬性。詳情請參閱 Potential Actions 頁面。

potentialAction.target

EntryPoint

含有這個 VideoObject 的網頁網址,其中會包括網址結構中的預留位置,指出 Google 可在哪個位置插入要在影片中略過的秒數。這關乎 Google 如何解讀您的網址結構,以及您採用的時間戳記格式。 請將網址的時間戳記部分替換成下列預留位置字串:

{seek_to_second_number}

舉例來說,請取代網址中的時間戳記部分:

"target": "https://video.example.com/watch/videoID?t=30"
時間戳記現在看起來會像這樣:
"target": "https://video.example.com/watch/videoID?t={seek_to_second_number}"

透過 Search Console 監控複合式搜尋結果

Search Console 這項工具能協助您監控網頁在 Google 搜尋中的成效。 Google 會主動將您的網頁納入搜尋結果,您無需為此申請使用 Search Console,但是您可以藉由這項服務瞭解並改善 Google 檢索您網站的方式。建議在下列情況查看 Search Console:

  1. 首次部署結構化資料後
  2. 發布新範本或更新程式碼後
  3. 定期分析流量

首次部署結構化資料後

在 Google 為網頁建立索引後,請透過相關的複合式搜尋結果狀態報告查看是否存在任何問題。理想情況下,有效項目會增加,但無效項目不會變多。如果您在結構化資料中發現問題,請依下列步驟操作:

  1. 修正無效項目
  2. 檢查線上網址,查看問題是否仍繼續發生。
  3. 透過狀態報告要求驗證

發布新範本或更新程式碼後

當您對網站進行大幅變更時,請留意結構化資料中無效項目是否增加。
  • 如果無效項目增加,代表您推出的新範本可能無法正常運作,或者您的網站採用新方式與現有範本互動,但效果不佳。
  • 如果有效項目減少,但錯誤並未隨之增加,代表您的網頁可能已不再內嵌結構化資料。請使用網址檢查工具找出問題的成因。

定期分析流量

透過成效報表分析您的 Google 搜尋流量。 這些資料會顯示您的網頁在 Google 搜尋中呈現為複合式搜尋結果的頻率、使用者點擊的頻率,以及您的搜尋結果平均排名。您也可以使用 Search Console API 自動提取這些結果。

疑難排解

如果無法順利導入結構化資料,或是偵錯時遇到困難,請參考下列資源。

  • 如果您使用內容管理系統 (CMS) 或者有他人代您處理網站事務,請向對方尋求協助。請務必將所有與問題相關的 Search Console 訊息都轉寄給對方,這些訊息會針對問題提供詳細說明。
  • Google 不保證採用結構化資料的功能一定會顯示在搜尋結果中。如要瞭解為何 Google 無法將您的內容顯示為複合式搜尋結果,請參閱結構化資料通用指南裡的常見原因清單。
  • 結構化資料可能含有錯誤。請查看結構化資料錯誤清單
  • 如果您的網頁遭到結構化資料專人介入處理處置,系統會忽略網頁上的結構化資料,但該網頁仍然會出現在 Google 搜尋結果中。請使用專人介入處理報告來修正結構化資料問題
  • 再次查看指南規範,確認您的內容是否符合規定。問題可能是因為垃圾內容或不當使用的標記所引起。不過,因為問題可能與語法無關,所以複合式搜尋結果測試無法找出問題所在。
  • 疑難排解:未出現複合式搜尋結果/複合式搜尋結果總數減少
  • 請等待一段時間,讓系統執行重新檢索和重新建立索引作業。在發布網頁後,Google 可能需要幾天時間才會找到網頁並進行檢索。如有關於檢索和索引建立作業的一般問題,請參閱 Google 搜尋檢索和索引常見問題
  • 前往 Google 搜尋中心論壇發文提問。