AMP Validation Mastery with SEM.co

Track AMP pages

Curious about AMP page performance? New AMP recognition in SEM.co's Position Tracking report is here to assist, even if you haven't implemented AMP yet.

Introduced by Google in February 2016, AMP, or Accelerated Mobile Pages, remains the cornerstone of mobile search results worldwide, augmenting user experience and offering diverse promotional avenues for webmasters, especially with AMP validation.Google Carousel and AMP-based featured snippets are invaluable benefits for SEO experts.

However, there’s currently a notable absence of tools addressing key concerns shared by webmasters utilizing this format:

  1. Lack of real-time website health monitoring.
  2. Absence of comprehensive reports consolidating all AMP checks.
  3. Inability to identify issues across all pages simultaneously.

SEMrush aims to disrupt this trend. In response to evolving user needs, we’ve crafted innovative solutions that meticulously address AMP-related issues on your website, enabling you to prioritize fixes and adopt optimal optimization techniques unlike any other tool available.

Even if you’re undecided about implementing AMP, our expertise includes AMP validation, ensuring we can guide you toward the most beneficial course of action.

AMP Validation: Monitoring AMP Pages

Curious about the performance of your AMP pages? Don’t have any accelerated mobile pages yet? Either way, you’ll find the newly integrated AMP recognition in SEM.co Position Tracking report beneficial.

"AMP Validation in SEMrush Position Tracking Report"

To view accelerated mobile pages in your Rankings Overview, ensure you’re targeting mobile devices in your position tracking campaign. Once set up, the tool will direct you to a tab displaying:

  • Rankings of AMP pages by target keywords
  • Specific SERPs for these keywords
  • Identification of whether the displayed AMP page belongs to you or a competitor

With this information, you can determine the necessity of AMP implementation or assess adjustments to your optimization strategy.

Yet, if simply configuring all your pages to meet the AMP HTML Specification were feasible, you wouldn’t be seeking this information.

Fortunately, SEMrush Site Audit now incorporates an AMP audit feature, enabling you to assess the AMP situation on your website at any time.

The AMP audit encompasses over 40 checks, categorized into three groups familiar to you:

  1. HTML issues
  2. Style and layout issues
  3. Templating issues

"AMP Validation Highlighted in SEMrush Site Audit Report"

Let’s delve deeper into AMP validation errors and explore methods to address them.

A – Adapt your HTML

"AMP HTML Validation Concerns"

The process of enhancing HTML with new AMP properties necessitated the imposition of limitations on certain HTML elements. Consequently, many webmasters find themselves grappling with HTML errors, which are prevalent among AMP issues. These errors are particularly critical as they negate the advantages of AMP that website owners seek to leverage.

For instance, when scrutinizing tags and attributes, webmasters must navigate through a lengthy list of whitelisted elements while contending with a vast amount of information regarding disallowed ones. Moreover, the introduction of new AMP-specific tags and custom elements further complicates the tasks of webmasters, particularly on larger websites.

Real-life Examples with AMP Validation

"Prohibited Tag Detected"

In line 1 of the page code, there is a disallowed tag ‘script,’ suggesting the potential use of custom JavaScript or incorrect implementation of an AMP component.

Due to their potential to hinder page load speed, ‘script’ tags are restricted by the AMP Specification, permitting their use only if the script type is application/ld+json or if it’s a mandatory script tag necessary for loading the AMP runtime/extended components. AMP validation ensures compliance with these specifications.

Sem.co advises removing the tag to optimize page performance.

"Remove Prohibited Tag"

Here is a different example.

"Issue with Invalid URL Protocol"

We’ve detected an invalid URL protocol in line 58. The ‘img’ tag specifies ‘http’ protocol for the ‘src’ attribute, causing the image to fail to render.

To resolve this issue, it’s recommended to update the protocol to a valid one. Typically, for graphics, this involves replacing ‘http’ with ‘https’.

"Update URL Protocol to Valid Format"
"AMP Style and Layout Challenges"

B – Beet style and layout

Meticulously controlling the styling and layout of an AMP page ensures quick loading times. Ignoring style and layout issues can risk search engines excluding your page entirely from search engine results pages (SERPs).

AMP styling relies on CSS, but faces challenges due to restrictions and disallowed styles, as well as the prohibition of external style sheets.

Additionally, there’s a requirement to include height and width attributes for each displayed tag, facilitating smooth scrolling. However, manually inserting these attributes can be time-consuming. Fortunately, the AMP validator assumes values for several layouts, reducing the manual effort required. Therefore, it’s more efficient to focus on addressing style and layout issues that directly impact your page’s performance.

highlighting  AMP validation error

Additional issues may arise from the use of common HTML attributes instead of custom AMP attributes, or from occasional errors in file paths.

Highlighting style and layout issues in AMP validation page

In the AMP Pages With Style and Layout Issues report, there are typically no specific “how-to-fix” tips provided because the solution to these problems often stems from the inherent nature of the issue.

C – Clear Off Unsupported Templating Syntax 

"AMP Template Challenges"

In the AMP format, dynamic content can be rendered using templates defined within the AMP document. However, these templates must be enclosed within specially designed tags. The AMP validator scrutinizes the syntax of the templating language to safeguard AMP documents from various vulnerabilities commonly encountered on the web.

"An Attribute in a Tag Contains Unescaped Mustache Syntax in a URL"

Templating issues are infrequent, and the primary recommendation in such cases is to escape the prohibited template or its partial.

"Escape Mustache Template in the URL Attribute"

As you can observe, Sem.co has achieved remarkable results, enabling you to:

  • Identify and resolve critical errors proactively, even before Google notifies you.
  • Quickly pinpoint the exact line of code where errors occur.
  • Receive practical how-to-fix-it tips in real-time.

Understanding that maintaining website health and staying updated with SEO trends can be a continuous challenge offers the SEM.co Site Audit as a comprehensive solution. Whether you’re an SEO agency owner or an in-house web developer, this tool provides invaluable assistance, eliminating the need to juggle multiple applications simultaneously.