Connect with us

MARKETING

4 Common Mistakes E-commerce Websites Make Using JavaScript

Published

on

4 Common Mistakes E-commerce Websites Make Using JavaScript

The author’s views are entirely his or her own (excluding the unlikely event of hypnosis) and may not always reflect the views of Moz.

Despite the resources they can invest in web development, large e-commerce websites still struggle with SEO-friendly ways of using JavaScript.

And, even when 98% of all websites use JavaScript, it’s still common that Google has problems indexing pages using JavaScript. While it’s okay to use it on your website in general, remember that JavaScript requires extra computing resources to be processed into HTML code understandable by bots.

At the same time, new JavaScript frameworks and technologies are constantly arising. To give your JavaScript pages the best chance of indexing, you’ll need to learn how to optimize it for the sake of your website’s visibility in the SERPs.

Why is unoptimized JavaScript dangerous for your e-commerce?

By leaving JavaScript unoptimized, you risk your content not getting crawled and indexed by Google. And in the e-commerce industry, that translates to losing significant revenue, because products are impossible to find via search engines.

Advertisement

It’s likely that your e-commerce website uses dynamic elements that are pleasant for users, such as product carousels or tabbed product descriptions. This JavaScript-generated content very often is not accessible to bots. Googlebot cannot click or scroll, so it may not access all those dynamic elements.

Consider how many of your e-commerce website users visit the site via mobile devices. JavaScript is slower to load so, the longer it takes to load, the worse your website’s performance and user experience becomes. If Google realizes that it takes too long to load JavaScript resources, it may skip them when rendering your website in the future.

Top 4 JavaScript SEO mistakes on e-commerce websites

Now, let’s look at some top mistakes when using JavaScript for e-commerce, and examples of websites that avoid them.

1. Page navigation relying on JavaScript

Crawlers don’t act the same way users do on a website ‒ they can’t scroll or click to see your products. Bots must follow links throughout your website structure to understand and access all your important pages fully. Otherwise, using only JavaScript-based navigation may make bots see products just on the first page of pagination.

Guilty: Nike.com

Nike.com uses infinite scrolling to load more products on its category pages. And because of that, Nike risks its loaded content not getting indexed.

For the sake of testing, I entered one of their category pages and scrolled down to choose a product triggered by scrolling. Then, I used the “site:” command to check if the URL is indexed in Google. And as you can see on a screenshot below, this URL is impossible to find on Google:

Advertisement
1669680614 203 4 Common Mistakes E commerce Websites Make Using JavaScript

Of course, Google can still reach your products through sitemaps. However, finding your content in any other way than through links makes it harder for Googlebot to understand your site structure and dependencies between the pages.

To make it even more apparent to you, think about all the products that are visible only when you scroll for them on Nike.com. If there’s no link for bots to follow, they will see only 24 products on a given category page. Of course, for the sake of users, Nike can’t serve all of its products on one viewport. But still, there are better ways of optimizing infinite scrolling to be both comfortable for users and accessible for bots.

4 Common Mistakes E commerce Websites Make Using JavaScript

Winner: Douglas.de

Unlike Nike, Douglas.de uses a more SEO-friendly way of serving its content on category pages.

They provide bots with page navigation based on <a href> links to enable crawling and indexing of the next paginated pages. As you can see in the source code below, there’s a link to the second page of pagination included:

1669680614 550 4 Common Mistakes E commerce Websites Make Using JavaScript

Moreover, the paginated navigation may be even more user-friendly than infinite scrolling. The numbered list of category pages may be easier to follow and navigate, especially on large e-commerce websites. Just think how long the viewport would be on Douglas.de if they used infinite scrolling on the page below:

4 Common Mistakes E commerce Websites Make Using JavaScript

2. Generating links to product carousels with JavaScript

Product carousels with related items are one of the essential e-commerce website features, and they are equally important from both the user and business perspectives. Using them can help businesses increase their revenue as they serve related products that users may be potentially interested in. But if those sections over-rely on JavaScript, they may lead to crawling and indexing issues.

Guilty: Otto.de

I analyzed one of Otto.de’s product pages to identify if it includes JavaScript-generated elements. I used the What Would JavaScript Do (WWJD) tool that shows screenshots of what a page looks like with JavaScript enabled and disabled.

Test results clearly show that Otto.de relies on JavaScript to serve related and recommended product carousels on its website. And from the screenshot below, it’s clear that those sections are invisible with JavaScript disabled:

1669680614 67 4 Common Mistakes E commerce Websites Make Using JavaScript

How may it affect the website’s indexing? When Googlebot lacks resources to render JavaScript-injected links, the product carousels can’t be found and then indexed.

Let’s check if that’s the case here. Again, I used the “site:” command and typed the title of one of Otto.de’s product carousels:

1669680614 543 4 Common Mistakes E commerce Websites Make Using JavaScript

As you can see, Google couldn’t find that product carousel in its index. And the fact that Google can’t see that element means that accessing additional products will be more complex. Also, if you prevent crawlers from reaching your product carousels, you’ll make it more difficult for them to understand the relationship between your pages.

Winner: Target.com

In the case of Target.com’s product page, I used the Quick JavaScript Switcher extension to disable all JavaScript-generated elements. I paid particular attention to the “More to consider” and “Similar items” carousels and how they look with JavaScript enabled and disabled.

Advertisement

As shown below, disabling JavaScript changed the way the product carousels look for users. But has anything changed from the bots’ perspective?

1669680614 479 4 Common Mistakes E commerce Websites Make Using JavaScript

To find out, check what the HTML version of the page looks like for bots by analyzing the cache version.

To check the cache version of Target.com’s page above, I typed “cache:https://www.target.com/p/9-39-…”, which is the URL address of the analyzed page. Also, I took a look at the text-only version of the page.

1669680615 561 4 Common Mistakes E commerce Websites Make Using JavaScript

When scrolling, you’ll see that the links to related products can also be found in its cache. If you see them here, it means bots don’t struggle to find them, either.

However, keep in mind that the links to the exact products you can see in the cache may differ from the ones on the live version of the page. It’s normal for the products in the carousels to rotate, so you don’t need to worry about discrepancies in specific links.

But what exactly does Target.com do differently? They take advantage of dynamic rendering. They serve the initial HTML, and the links to products in the carousels as the static HTML bots can process.

However, you must remember that dynamic rendering adds an extra layer of complexity that may quickly get out of hand with a large website. I recently wrote an article about dynamic rendering that’s a must-read if you are considering this solution.

Also, the fact that crawlers can access the product carousels doesn’t guarantee these products will get indexed. However, it will significantly help them flow through the site structure and understand the dependencies between your pages.

Advertisement

3. Blocking important JavaScript files in robots.txt

Blocking JavaScript for crawlers in robots.txt by mistake may lead to severe indexing issues. If Google can’t access and process your important resources, how is it supposed to index your content?

Guilty: Jdl-brakes.com

It’s impossible to fully evaluate a website without a proper site crawl. But looking at its robots.txt file can already allow you to identify any critical content that’s blocked.

This is the case with the robots.txt file of Jdl-brakes.com. As you can see below, they block the /js/ path with the Disallow directive. It makes all internally hosted JavaScript files (or at least the important ones) invisible to all search engine bots.

1669680615 258 4 Common Mistakes E commerce Websites Make Using JavaScript

This disallow directive misuse may result in rendering problems on your entire website.

To check if it applies in this case, I used Google’s Mobile-Friendly Test. This tool can help you navigate rendering issues by giving you insight into the rendered source code and the screenshot of a rendered page on mobile.

I headed to the “More info” section to check if any page resources couldn’t be loaded. Using the example of one of the product pages on Jdl-brakes.com, you may see it needs a specific JavaScript file to get fully rendered. Unfortunately, it can’t happen because the whole /js/ folder is blocked in its robots.txt.

1669680615 106 4 Common Mistakes E commerce Websites Make Using JavaScript

But let’s find out if those rendering problems affected the website’s indexing. I used the “site:” command to check if the main content (product description) of the analyzed page is indexed on Google. As you can see, no results were found:

1669680615 87 4 Common Mistakes E commerce Websites Make Using JavaScript

This is an interesting case where Google could reach the website’s main content but didn’t index it. Why? Because Jdl-brakes.com blocks its JavaScript, Google can’t properly see the layout of the page. And even though crawlers can access the main content, it’s impossible for them to understand where that content belongs in the page’s layout.

Let’s take a look at the Screenshot tab in the Mobile-Friendly Test. This is how crawlers see the page’s layout when Jdl-brakes.com blocks their access to CSS and JavaScript resources. It looks pretty different from what you can see in your browser, right?

Advertisement
1669680615 981 4 Common Mistakes E commerce Websites Make Using JavaScript

The layout is essential for Google to understand the context of your page. If you’d like to know more about this crossroads of web technology and layout, I highly recommend looking into a new field of technical SEO called rendering SEO.

Winner: Lidl.de

Lidl.de proves that a well-organized robots.txt file can help you control your website’s crawling. The crucial thing is to use the disallow directive consciously.

Although Lidl.de blocks a single JavaScript file with the Disallow directive /cc.js*, it seems it doesn’t affect the website’s rendering process. The important thing to note here is that they block only a single JavaScript file that doesn’t influence other URL paths on a website. As a result, all other JavaScript and CSS resources they use should remain accessible to crawlers.

1669680615 129 4 Common Mistakes E commerce Websites Make Using JavaScript

Having a large e-commerce website, you may easily lose track of all the added directives. Always include as many path fragments of a URL you want to block from crawling as possible. It will help you avoid blocking some crucial pages by mistake.

4. JavaScript removing main content from a website

If you use unoptimized JavaScript to serve the main content on your website, such as product descriptions, you block crawlers from seeing the most important information on your pages. As a result, your potential customers looking for specific details about your products may not find such content on Google.

Guilty: Walmart.com

Using the Quick JavaScript Switcher extension, you can easily disable all JavaScript-generated elements on a page. That’s what I did in the case of one of Walmart.com’s product pages:

1669680615 676 4 Common Mistakes E commerce Websites Make Using JavaScript

As you can see above, the product description section disappeared with JavaScript disabled. I decided to use the “site:” command to check if Google could index this content. I copied the fragment of the product description I saw on the page with JavaScript enabled. However, Google didn’t show the exact product page I was looking for.

1669680615 790 4 Common Mistakes E commerce Websites Make Using JavaScript

Will users get obsessed with finding that particular product via Walmart.com? They may, but they can also head to any other store selling this item instead.

The example of Walmart.com proves that main content depending on JavaScript to load makes it more difficult for crawlers to find and display your valuable information. However, it doesn’t necessarily mean they should eliminate all JavaScript-generated elements on their website.

To fix this problem, Walmart has two solutions:

Advertisement
  1. Implementing dynamic rendering (prerendering) which is, in most cases, the easiest from an implementation standpoint.

  2. Implementing server-side rendering. This is the solution that will solve the problems we are observing at Walmart.com without serving different content to Google and users (as in the case of dynamic rendering). In most cases, server-side rendering also helps with web performance issues on lower-end devices, as all of your JavaScript is being rendered by your servers before it reaches the client’s device.

Let’s have a look at the JavaScript implementation that’s done right.

Winner: IKEA.com

IKEA proves that you can present your main content in a way that is accessible for bots and interactive for users.

When browsing IKEA.com’s product pages, their product descriptions are served behind clickable panels. When you click on them, they dynamically appear on the right-hand side of the viewport.

Although users need to click to see product details, Ikea also serves that crucial part of its pages even with JavaScript off:

1669680615 113 4 Common Mistakes E commerce Websites Make Using JavaScript

This way of presenting crucial content should make both users and bots happy. From the crawlers’ perspective, serving product descriptions that don’t rely on JavaScript makes them easy to access. Consequently, the content can be found on Google.

Wrapping up

JavaScript doesn’t have to cause issues, if you know how to use it properly. As an absolute must-do, you need to follow the best practices of indexing. It may allow you to avoid basic JavaScript SEO mistakes that can significantly hinder your website’s visibility on Google.

Take care of your indexing pipeline and check if:

Advertisement
  • You allow Google access to your JavaScript resources,

  • Google can access and render your JavaScript-generated content. Focus on the crucial elements of your e-commerce site, such as product carousels or product descriptions,

  • Your content actually gets indexed on Google.

If my article got you interested in JS SEO, find more details in Tomek Rudzki’s article about the 6 steps to diagnose and solve JavaScript SEO issues.

Source link

Keep an eye on what we are doing
Be the first to get latest updates and exclusive content straight to your email inbox.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address

MARKETING

How To Combine PR and Content Marketing Superpowers To Achieve Business Goals

Published

on

A figure pulls open a dress shirt to reveal the term PR on a Superman-like costume, reflecting the superpower resulting from combining content and PR.

A transformative shift is happening, and it’s not AI.

The aisle between public relations and content marketing is rapidly narrowing. If you’re smart about the convergence, you can forever enhance your brand’s storytelling.

The goals and roles of content marketing and PR overlap more and more. The job descriptions look awfully similar. Shrinking budgets and a shrewd eye for efficiency mean you and your PR pals could face the chopping block if you don’t streamline operations and deliver on the company’s goals (because marketing communications is always first to be axed, right?).

Yikes. Let’s take a big, deep breath. This is not a threat. It’s an opportunity.

Advertisement

Reach across the aisle to PR and streamline content creation, improve distribution strategies, and get back to the heart of what you both are meant to do: Build strong relationships and tell impactful stories.

So, before you panic-post that open-to-work banner on LinkedIn, consider these tips from content marketing, PR, and journalism pros who’ve figured out how to thrive in an increasingly narrowing content ecosystem.

1. See journalists as your audience

Savvy pros know the ability to tell an impactful story — and support it with publish-ready collateral — grounds successful media relationships. And as a content marketer, your skills in storytelling and connecting with audiences, including journalists, naturally support your PR pals’ media outreach.

Strategic storytelling creates content focused on what the audience needs and wants. Sharing content on your blog or social media builds relationships with journalists who source those channels for story ideas, event updates, and subject matter experts.

“Embedding PR strategies in your content marketing pieces informs your audience and can easily be picked up by media,” says Alex Sanchez, chief experience officer at BeWell, New Mexico’s Health Insurance Marketplace. “We have seen reporters do this many times, pulling stories from our blogs and putting them in the nightly news — most of the time without even reaching out to us.”

Acacia James, weekend producer/morning associate producer at WTOP radio in Washington, D.C., says blogs and social media posts are helpful to her work. “If I see a story idea, and I see that they’re willing to share information, it’s easier to contact them — and we can also backlink their content. It’s huge for us to be able to use every avenue.” 

Advertisement

Kirby Winn, manager of PR at ImpactLife, says reporters and assignment editors are key consumers of their content. “And I don’t mean a news release that just hit their inbox. They’re going to our blog and consuming our stories, just like any other audience member,” he says. “Our organization has put more focus into content marketing in the past few years — it supports a media pitch so well and highlights the stories we have to tell.”

Storytelling attracts earned media that might not pick up the generic news topic. “It’s one thing to pitch a general story about how we help consumers sign up for low-cost health insurance,” Alex says. “Now, imagine a single mom who just got a plan after years of thinking it was too expensive. She had a terrible car accident, and the $60,000 ER bill that would have ruined her financially was covered. Now that’s a story journalists will want to cover, and that will be relatable to their audience and ours.” 

2. Learn the media outlet’s audience

Seventy-three percent of reporters say one-fourth or less of the stories pitched are relevant to their audiences, according to Cision’s 2023 State of the Media Report (registration required).

PR pros are known for building relationships with journalists, while content marketers thrive in building communities around content. Merge these best practices to build desirable content that works for your target audience and the media’s audiences simultaneously.

WTOP’s Acacia James says sources who show they’re ready to share helpful, relevant content often win pitches for coverage. “In radio, we do a lot of research on who is listening to us, and we’re focused on a prototype called ‘Mike and Jen’ — normal, everyday people in Generation X … So when we get press releases and pitches, we ask, ‘How interested will Mike and Jen be in this story?’” 

3. Deliver the full content package (and make journalists’ jobs easier)

Cranking out content to their media outlet’s standards has never been tougher for journalists. Newsrooms are significantly understaffed, and anything you can do to make their lives easier will be appreciated and potentially rewarded with coverage. Content marketers are built to think about all the elements to tell the story through multiple mediums and channels.

Advertisement

“Today’s content marketing pretty much provides a package to the media outlet,” says So Young Pak, director of media relations at MedStar Washington Hospital Center. “PR is doing a lot of storytelling work in advance of media publication. We (and content marketing) work together to provide the elements to go with each story — photos, subject matter experts, patients, videos, and data points, if needed.”   

At WTOP, the successful content package includes audio. “As a radio station, we are focused on high-quality sound,” Acacia James says. “Savvy sources know to record and send us voice memos, and then we pull cuts from the audio … You will naturally want to do someone a favor if they did you one — like providing helpful soundbites, audio, and newsworthy stories.”  

While production value matters to some media, you shouldn’t stress about it. “In the past decade, how we work with reporters has changed. Back in the day, if they couldn’t be there in person, they weren’t going to interview your expert,” says Jason Carlton, an accredited PR professional and manager of marketing and communications at Intermountain Health. “During COVID, we had to switch to virtual interviewing. Now, many journalists are OK with running a Teams or Zoom interview they’ve done with an expert on the news.”

BeWell’s Alex Sanchez agrees. “I’ve heard old school PR folks cringe at the idea of putting up a Zoom video instead of getting traditional video interviews. It doesn’t really matter to consumers. Focus on the story, on the timeliness, and the relevance. Consumers want authenticity, not super stylized, stiff content.”

4. Unite great minds to maximize efficiency

Everyone needs to set aside the debate about which team — PR or content marketing — gets credit for the resulting media coverage.

At MedStar Washington Hospital Center, So Young and colleagues adopt a collaborative mindset on multichannel stories. “We can get the interview and gather information for all the different pieces — blog, audio, video, press release, internal newsletter, or magazine. That way, we’re not trying to figure things out individually, and the subject matter experts only have to have that conversation once,” she says.

Advertisement

Regular, cross-team meetings are essential to understand the best channels for reaching key audiences, including the media. A story that began life as a press release might reap SEO and earned media gold if it’s strategized as a blog, video, and media pitch.

“At Intermountain Health, we have individual teams for media relations, marketing, social media, and hospital communications. That setup works well because it allows us to bring in the people who are the given experts in those areas,” says Intermountain’s Jason Carlton. “Together, we decide if a story is best for the blog, a media pitch, or a mix of channels — that way, we avoid duplicating work and the risk of diluting the story’s impact.”

5. Measure what matters

Cutting through the noise to earn media mentions requires keen attention to metrics. Since content marketing and PR metrics overlap, synthesizing the data in your team meetings can save time while streamlining your storytelling efforts.

“For content marketers, using analytical tools such as GA4 can help measure the effectiveness of their content campaigns and landing pages to determine meaningful KPIs such as organic traffic, keyword rankings, lead generation, and conversion rates,” says John Martino, director of digital marketing for Visiting Angels. “PR teams can use media coverage and social interactions to assess user engagement and brand awareness. A unified and omnichannel approach can help both teams demonstrate their value in enhancing brand visibility, engagement, and overall business success.”

To track your shared goals, launch a shared dashboard that helps tell the combined “story of your stories” to internal and executive teams. Among the metrics to monitor:

  • Page views: Obviously, this queen of metrics continues to be important across PR and content marketing. Take your analysis to the next level by evaluating which niche audiences are contributing to these views to further hone your storytelling targets, including media outlets.
  • Earned media mentions: Through a media tracker service or good old Google Alerts, you can tally the echo of your content marketing and PR. Look at your site’s referral traffic report to identify media outlets that send traffic to your blog or other web pages.
  • Organic search queries: Dive into your analytics platform to surface organic search queries that lead to visitors. Build from those questions to develop stories that further resonate with your audience and your targeted media.
  • On-page actions: When visitors show up on your content, what are they doing? What do they click? Where do they go next? Building next-step pathways is your bread and butter in content marketing — and PR can use them as a natural pipeline for media to pick up more stories, angles, and quotes.

But perhaps the biggest metric to track is team satisfaction. Who on the collaborative team had the most fun writing blogs, producing videos, or calling the news stations? Lean into the natural skills and passions of your team members to distribute work properly, maximize the team output, and improve relationships with the media, your audience, and internal teams.

“It’s really trying to understand the problem to solve — the needle to move — and determining a plan that will help them achieve their goal,” Jason says. “If you don’t have those measurable objectives, you’re not going to know whether you made a difference.”

Advertisement

Don’t fear the merger

Whether you deliberately work together or not, content marketing and public relations are tied together. ImpactLife’s Kirby Winn explains, “As soon as we begin to talk about (ourselves) to a reporter who doesn’t know us, they are certainly going to check out our stories.”

But consciously uniting PR and content marketing will ease the challenges you both face. Working together allows you to save time, eliminate duplicate work, and gain free time to tell more stories and drive them into impactful media placements.

Register to attend Content Marketing World in San Diego. Use the code BLOG100 to save $100. Can’t attend in person this year? Check out the Digital Pass for access to on-demand session recordings from the live event through the end of the year.

HANDPICKED RELATED CONTENT:

Cover image by Joseph Kalinowski/Content Marketing Institute

Source link

Advertisement
Keep an eye on what we are doing
Be the first to get latest updates and exclusive content straight to your email inbox.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address
Continue Reading

MARKETING

Trends in Content Localization – Moz

Published

on

Trends in Content Localization - Moz

Multinational fast food chains are one of the best-known examples of recognizing that product menus may sometimes have to change significantly to serve distinct audiences. The above video is just a short run-through of the same business selling smokehouse burgers, kofta, paneer, and rice bowls in an effort to appeal to people in a variety of places. I can’t personally judge the validity of these representations, but what I can see is that, in such cases, you don’t merely localize your content but the products on which your content is founded.

Sometimes, even the branding of businesses is different around the world; what we call Burger King in America is Hungry Jack’s in Australia, Lays potato chips here are Sabritas in Mexico, and DiGiorno frozen pizza is familiar in the US, but Canada knows it as Delissio.

Tales of product tailoring failures often become famous, likely because some of them may seem humorous from a distance, but cultural sensitivity should always be taken seriously. If a brand you are marketing is on its way to becoming a large global seller, the best insurance against reputation damage and revenue loss as a result of cultural insensitivity is to employ regional and cultural experts whose first-hand and lived experiences can steward the organization in acting with awareness and respect.

Source link

Advertisement
Keep an eye on what we are doing
Be the first to get latest updates and exclusive content straight to your email inbox.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address
Continue Reading

MARKETING

How AI Is Redefining Startup GTM Strategy

Published

on

How AI Is Redefining Startup GTM Strategy

AI and startups? It just makes sense.

(more…)

Keep an eye on what we are doing
Be the first to get latest updates and exclusive content straight to your email inbox.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address
Continue Reading

Trending

Follow by Email
RSS