Google uses the mobile version of a site’s content, crawled with the
smartphone agent,
for indexing and ranking. This is called mobile-first indexing.
While it’s not required to have a mobile version of your pages to have your content included
in Google’s Search results, it is very strongly recommended. These best practices apply to
mobile sites in general, and by definition to mobile-first indexing.
To make sure that your users have the best experience, follow the best practices detailed in
this guide.
Create a mobile-friendly site
If you haven’t already, create a mobile-friendly website so your users visiting your site
through a mobile phone can have a stellar experience. There are three configurations you can
choose from to create a mobile-friendly site:
- Responsive design:
Serves the same HTML code on the same URL regardless of the users’ device (for example,
desktop, tablet, mobile, non-visual browser), but can display the content differently based
on the screen size. Google recommends Responsive Web Design because it’s the easiest
design pattern to implement and maintain. - Dynamic serving: Uses the same URL regardless of device. This
configuration relies on
user-agentsniffing
and the
Vary: user-agentHTTP response header
to serve a different version of the HTML to different devices. - Separate URLs: Serves different HTML to each device, and on separate URLs.
Like dynamic serving, this configuration relies on theuser-agentand
VaryHTTP headers to redirect users to the device-appropriate version of the
site.
The contents of this guide only apply to dynamic serving and separate URL configurations. In
case of responsive design, the content and the metadata are the same on the mobile and desktop
version of the pages.
Make sure that Google can access and render your content
Make sure that Google can access and render your mobile page content and resources.
- Use the same robots
metatags on the mobile and desktop site.
If you use a different robotsmetatag on the mobile site (especially the
noindexounofollowtags), Google may fail to crawl and index your
page when your site is enabled for mobile-first indexing. - Don’t lazy-load primary content upon user interaction. Google won’t load
content that requires user interactions (for example, swiping, clicking, or typing) to load.
Make sure that Google can see lazy-loaded content. - Let Google crawl your resources. Some resources have different URLs on the
mobile site from those on the desktop site. If you want Google to crawl your URLs, make sure
that you’re not blocking the URL with the
disallowrule.
Make sure that content is the same on desktop and mobile
Even with the equivalent content, differences in DOM or layout between desktop and mobile page
can result in Google understanding the content differently. However having the same content on
the desktop and mobile version ensures that the two versions can rank for the same keywords.
Make sure that your mobile site contains the same content as your desktop site.
If your mobile site has less content than your desktop site, consider updating your mobile
site so that its primary content is equivalent to your desktop site. You can have a
different design on mobile to maximize user experience (for example, moving content into
accordions or tabs); just make sure that the content is equivalent to the desktop site,
since indexing on your site comes from the mobile site.
Use the same clear and meaningful headings on the mobile site as you do on the
desktop site.
Check your structured data
If you have structured data on your site, make sure that it’s present on both versions of your
site. Here are some specific things to check:
- Make sure that your mobile and desktop sites have the same structured data.
If you have to prioritize which types you add to your mobile site, start with
Fil d’Ariane,
Product, and
VideoObject
structured data. - Use correct URLs in structured data. Make sure that URLs in the structured
data on the mobile versions are updated to the mobile URLs. - If you use Data Highlighter, train it on your mobile site. If you use
Data Highlighter
to provide structured data, regularly check the
Data Highlighter dashboard
for extraction errors.
Put the same metadata on both versions of your site
Make sure that the
title element and
the
meta description are
equivalent across both versions of your site.
Check the placement of your ads
Don’t let ads harm your mobile page ranking. Follow the
Better Ads Standard
when displaying ads on mobile devices. For example, ads at the top of the page can take up too
much room on a mobile device, which is a bad user experience
Check visual content
Check your images
Make sure that the images on your mobile site follow the
image best practices. In particular, we
recommend that you:
Provide
high quality images.
Don’t use images that are too small or have a low resolution on the mobile site.
Use a
supported format for images.
Don’t use unsupported formats or tags. For example, Google supports SVG format
images, but our systems can’t index a .jpg image in the<image>tag
inside an inline SVG.- Don’t use URLs that change every time the page loads for images. Google
won’t be able to process and index your resources properly if you use constantly-changing
URLs for them.
Make sure that the mobile site has the same alt text for images as the desktop site.
Use
descriptive alt text
for images on your mobile site as you do on your desktop site.
Make sure that the mobile page content quality is as good as the desktop page.
Use the same
titles, captions, filenames, and text
relevant to the images on the mobile site as you do for the desktop site.
Check your videos
Make sure that the videos on your mobile site follow the
video best practices. In particular, we
recommend that you:
- Don’t use URLs that change every time the page loads for your videos.
Google won’t be able to process and index your resources properly if you use constantly
changing URLs for them.
Use a supported format
for your videos and put videos in supported tags. Videos are identified in the
page by the presence of an HTML tag, for example:<video>,
<embed>, or<object>.- Use the same video structured data on both your mobile site and desktop
site. For more information, check your structured data.
Place the video in an easy to find position on the page when viewed on a mobile device.
For example, it might harm the video’s ranking if users need to scroll down too
much to find the video on mobile page.
Additional best practices for separate URLs
If your site has separate URLs for the desktop and mobile versions of a page (also known as
m-dot), we recommend the following additional best practices:
Make sure that the error page status is the same on both the desktop and mobile sites.
If a page on your desktop site serves normal contents and your mobile site’s
version of that page serves an error page, this page will be missing from the index.- Make sure that your mobile version doesn’t have URL fragments. The fragment
part of the URL is the end of the URL that starts with#. Most of the time,
URL fragments are not indexable, these pages will be missing from the index after your
domain is enabled for mobile-first indexing.
Ensure that the desktop versions that serve different contents have equivalent mobile
versions.
If different URLs redirect to the same URL (for example, to the home page on mobile
devices) after your domain is enabled for mobile-first indexing, all these pages will be
missing from the index.
Verify both versions of your site in
Search Console
to make sure that you have access to data and messages for both versions. Your
site may experience a data shift when Google switches to mobile-first indexing for your
site.Check
hreflanglinks on separate URLs. When you use
rel=hreflang
linkelements
for
internationalization,
link between mobile and desktop URLs separately. Your mobile URLs’hreflang
must point to mobile URLs, and similarly desktop URLhreflangmust point to
desktop URLs.Here’s an example of
hreflangfor the home page of a site with separate URLs
for mobile and desktop.Mobile
In this example, the mobile site URL is
https://m.example.com/.Desktop
In this example, the desktop site URL is
https://example.com/.- Ensure that your mobile site has enough capacity to handle a potential
increase in
crawl rate
on the mobile version of your site.
Verify that your
robots.txt rules
work as you intend for both versions of your site. The robots.txt file lets you
specify which parts of a website may be crawled or not. In most cases, use the same
robots.txt rules for both mobile and desktop versions of your site.
Use the correctrel=canonicalandrel=alternate
linkelements
between your mobile and desktop versions. The desktop URL is always the canonical,
and the mobile version is the alternate of that URL.Here’s an example of
rel=canonicalandrel=alternatefor a
separate URLs site setup.Mobile
In this example, the mobile site URL is
https://m.example.com/and
includes alinkelement that points to the desktop URL as
the canonical URL.Desktop
In this example, the desktop site URL is
https://example.com/and
includes alinkelement that points to itself as the canonical URL,
followed by anotherlinkelement that points to the mobile version as the
alternate version of this URL.
Troubleshooting
Here’s a list of the most common errors that can stop sites from being enabled for
mobile-first indexing or could cause a drop in ranking after a site is enabled for
mobile-first indexing. If your site isn’t enabled for mobile-first indexing yet, you’ve seen a
drop in ranking after your site is enabled for mobile-first indexing, or you’ve received a
message in Search Console, check the following list of common errors and resolve possible
errors you may have:
| Errors | |
|---|---|
Missing structured data | error What caused the issue: The mobile page doesn’t have all the structured data markup that the desktop page has. done Fix the issue
|
| error What caused the issue: A mobile page is blocked from indexing by a noindex tag.done Fix the issue: |
Missing image | error What caused the issue: The mobile page doesn’t have all the important images that the desktop page has. done Fix the issue
|
Blocked image | error What caused the issue: An important image on the mobile page is blocked by robots.txt. done Fix the issue: |
Low quality image | error What caused the issue: An important image on the mobile page is too small or low resolution. done Fix the issue: |
Missing alt text | error What caused the issue: An important image on the mobile page is missing alt text. done Fix the issue: |
Missing page title | error What caused the issue: A mobile page is missing a title. done Fix the issue: |
Missing meta description | error What caused the issue: A mobile page is missing the meta description. done Fix the issue: |
Mobile URL is an error page | error What caused the issue: The mobile page is an error page. done Fix the issue: |
Mobile URL has anchor fragment | error What caused the issue: The mobile URL includes an anchor fragment; Google can’t index URLs that include fragments. done Fix the issue: |
Mobile page blocked by robots.txt | error What caused the issue: The mobile page is blocked by a robots.txt rule. done Fix the issue: |
Duplicate mobile page target | error What caused the issue: Multiple desktop pages redirect to the same mobile page. done Fix the issue: |
Desktop site redirects to the mobile home page | error What caused the issue: Most or all pages on your desktop site redirect to the mobile site’s home page. done Fix the issue: |
Page quality issues | error What caused the issue: The mobile page has issues with ads, missing content, titles, or descriptive elements for images on the page. done Fix the issue:
|
Video issues | error What caused the issue: The mobile page has a video that is not in a supported format, is placed in a difficult to find location, is missing meta descriptions, or is very slow to load. done Fix the issue:
|
Hostload issues | error What caused the issue: Some of the hosts don’t have enough hostload. done Fix the issue: |
Comment nous l'appliquons
Mobile-first indexing means the mobile page is the page. We check that mobile templates carry the same content, structured data and metadata as desktop, since the most common cause of a silent traffic loss is a stripped-down mobile view.
Services associés