Skip to content
検索します

Hreflangタグ:概要と動作方法

hreflangタグは、ページのどの言語・地域版をユーザーに表示すべきかを検索エンジンに指示します。インデックス登録と配信で適切なバリアント選択を助けますが、単独で順位を決定するものではありません。

Hreflang Tag: Guide for Multilingual Websites

概要

Hreflangは、ページ、HTTPヘッダー、またはXMLサイトマップに追加するHTML/ハイパーリンクのシグナルで、代替URLの言語と任意の地域ターゲティングを宣言します。検索エンジン は、特定の言語や地域のユーザーに対して最適なローカライズされたURLを表示するためにhreflangを利用します。Hreflangは、検索エンジンがどのバリアントをインデックス登録し表示するかに影響しますが、クエリにおけるその言語やロケール向けのもので、検索結果の順位を単独で決定する直接のランキングシグナルではありません。

要点:hreflangエントリはバリアント間で一貫していること、自己参照のリンクを含むこと、正しい言語-地域コード(ISO 639-1 / ISO 3166-1)を使用すること、そしてインデックス作成にクローラーのバージョンに適用すること — Googleの場合はモバイル版が主要な基準です(Google crawls with Googlebot Smartphone by default since July 2024)。

ステップバイステップ

以下の手順でhreflangを確実に追加できます。

1) コードとcanonical戦略の選定

言語のみのコード(例えば "en")、言語-地域コード(例えば "en-GB")、または両方を使うかを決めます。canonicalとhreflangは整合性を保ってください:各ローカライズされたページは自己参照するhreflangと自身を指すcanonicalを持てますが、hreflangが異なる言語のcanonicalを指してはいけません。

2) 配置方法の選択:link要素、HTTPヘッダー、またはXMLサイトマップ

hreflangを宣言する一般的な方法は3つあり、それぞれトレードオフがあります:

- HTML <link> elements in the <head> — pros: simple, easy to audit in source; cons: requires identical head on all device versions (ensure mobile parity). Example: <link rel="alternate" hreflang="en" href="https://example.com/en/">

- HTTP headers — pros: useful for non-HTML files (PDFs); cons: harder to manage and audit. Example header: Link: <https://example.com/fr/>; rel="alternate"; hreflang="fr"

- XML sitemaps with <xhtml:link> entries — pros: centralised for large sites and sitewide variants; cons: must maintain accurate URLs and ensure sitemap is accessible to crawlers.

3) 双方向の完全なセット(相互性)を実装する

列挙するすべての代替URLは、他のすべての代替(元のページを含む)も列挙していなければなりません。例えば、ページAがA、B、Cを列挙するなら、ページBもA、B、Cを列挙し、ページCもA、B、Cを列挙する必要があります。相互性はクローラーのあいまいさを減らし、正しいバリアント選択に寄与します。

よくある問題

インデックス登録や表示に影響する、実装時の典型的なエラー。

- Wrong or inconsistent codes (mixing en and en-US) — can cause search engines to ignore entries or choose a different variant.

- Missing self-referential tag — if a page does not include itself in the list, reciprocity fails and alternate selection can be incorrect.

- Non-indexable or blocked pages (noindex, robots disallow) — an alternate that is not indexable is usually less useful; search engines may ignore it when constructing variant sets.

- Mixing relative and absolute URLs, or HTTP/HTTPS mismatch — use absolute, canonicalized URLs that match the version crawlers access.

検証とトラブルシューティング方法

検証方法は、サイトを所有しているか第三者を監査しているかで異なります。自身が所有するページについてはGoogle Search ConsoleのURL検査(URL Inspection)を使って、Googleがページをどのようにインデックス登録したか、どのバリアントを選んだかを確認してください。どのサイトに対しても、以下の一般的なツールでHTTPやレンダリングのチェックを行ってください。

ツールとコマンド

Chrome DevTools(View Source と Elements) — サーブされたHTMLに <link rel="alternate" hreflang="..."> エントリが存在し、モバイル責任ページ上で確認できるか検証します。

curl -I https://example.com/path/ — レスポンスヘッダーのみを表示(サーバーヘッダーやLinkヘッダーの確認に有用)。

curl https://example.com/path/ — HTML本体を取得;サーバーがGooglebotに対して何を返すかを見るには curl -A "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" https://example.com/path/ を使ってサーバーがGooglebotのUser-Agentに対して何を返すかを確認できます(これをクロークに使用しないでください — サーバー応答を監査するためだけに使用してください)。

Bing Webmaster Tools Site Explorer — Bingのクロール挙動やインデックス信号を確認します。

Note: URL Inspection in Google Search Console is authoritative for pages you own; for third-party pages you must rely on public fetches and indexation signals such as site: queries (which are indicative, not definitive).

実務チェックリスト

- **Hreflang present on canonical/mobile version** — where to verify: view-source or curl as mobile UA — passes when all variants list the same set of hreflang entries.
- **Self-referential entry** — where to verify: page source — passes when the current URL appears in the set.
- **Reciprocity across variants** — where to verify: check each variant's source or sitemap — passes when every variant lists every alternative.
- **Indexability of alternates** — where to verify: URL Inspection (own site) or site: operator and public fetch — passes when alternates are crawlable and not blocked by robots or noindex.
- **URL canonical and protocol parity** — where to verify: HTTP headers and canonical link — passes when hreflang href values match canonical and use the same scheme (https/http) that users and crawlers reach.
- **x-default for fallback** — where to verify: page source or sitemap — passes when a sensible fallback (homepage or language selector landing) is marked with hreflang="x-default".

FAQの前に:より技術的な参照が必要な場合は、Read the Technical SEO Guide を参照してください

よくある質問

hreflangはランキングを向上させますか?

hreflangは検索エンジンが適切な言語/地域バリアントを配信するのに役立ち、重複コンテンツの混乱を減らせますが、単独で順位を上げるものではありません。検索結果の順位決定には多くのランキングシグナルが関与します。

hreflangと国別サイトのどちらをいつ使うべきか?

コンテンツが実質的に同じで、異なる言語や地域向けのバリアントを別URL(サブディレクトリ、サブドメイン、またはccTLD)でホストしている場合はhreflangを使います。市場ごとにコンテンツやビジネスルールが大きく異なる場合は、別の国別サイトが適切です。

x-defaultタグは必要ですか?

x-defaultは、(例:言語セレクターのランディングページなど)あいまいなケースで推奨されます。検索エンジンが厳密な言語一致を見つけられない場合の明確なフォールバックになります。

hreflangはcanonicalタグと併用できますか?

はい。各ローカライズページは自身を指すcanonicalを持ち、他のローカライズ版を列挙するhreflangエントリを含めることができます。hreflangが別言語のcanonicalを指すことは避けてください。

最終的な注意点:hreflangはインデックス登録とバリアント選択を助けますが、一貫して実装・維持される必要があります。ブラウザのDevTools、curl、Search Console(自身のサイト用)による定期的な監査が、回帰を検出する最も信頼できる方法です。

質の高いbacklinksで権威性を構築するTechnical SEOと適切な国際ターゲティングはオーガニック成長に不可欠な要素です。関連性がありインデックス可能な配置から得られるオーソリティは、正しいhreflang設定を補完し、ユーザーが適切なバリアントを見つける手助けになります。

関連用語