---
canonical: "https://www.jsolly.com/blog/get-a-perfect-score-on-seo-tool-ahrefs/"
title: "Improving Website Health With Ahrefs: A Step-by-Step Guide"
description: "Improve website's health score with Ahrefs and eliminate duplicate pages. Tips on fixing common issues and implementing new features."
author: "John Solly"
published: "2022-10-26T22:43:09.583Z"
updated: "2022-10-26T22:43:09.583Z"
---

<a id="improving-website-health-with-ahrefs-a-step-by-step-guide"></a>

# Improving Website Health With Ahrefs: A Step-by-Step Guide

![John Solly Headshot](https://d1d7p8ufhgz4ld.cloudfront.net/media/post_metaimgs/ahrefScore.webp)

[Ahrefs](https://ahrefs.com/) is an SEO tool that identifies issues on your websites, like broken links, missing alt-text, and more. When I first ran the tool, my site got a 44/100 😭

![Ahrefs health score of 44/100](https://d1d7p8ufhgz4ld.cloudfront.net/media/post_imgs/image_ojFXOEx.png)

<a id="top-issues"></a>

## Top Issues

Here's a screenshot of the problems Ahrefs encountered on blogthedata.com

![A list of top issues according to ahrefs. The highlight is 215 pages without canonical.](https://d1d7p8ufhgz4ld.cloudfront.net/media/post_imgs/image_FwTrFpJ.png)

<a id="alt-text-h1-tags-meta-descriptionstitles"></a>

## Alt-text, H1 tags, meta descriptions/titles

These were pretty straightforward fixes. Images should have alt-text for non-sighted users, and every page should have an H1 tag as the main header.

Meta descriptions and titles are meta tags in <head> are used for social media previews and search engines. I needed to finesse mine to ensure they were in the Goldilocks zone, not too long or too short!

<a id="duplicate-pages-without-canonical"></a>

## Duplicate Pages Without Canonical

Search engine crawlers treat the same URLs as duplicates if your site supports 'www' and no 'www' (known as the 'apex' domain). For example,

https://www.blogthedata.com 

and

https://blogthedata.com 

Technically, both of those are on separate domains, so I was getting flagged for duplicate content. To resolve this issue, I found [this article](https://developers.cloudflare.com/pages/how-to/www-redirect/) by Cloudflare, which walks you through how you can set up bulk redirects, so anyone visiting a 'www' URL gets redirected to one without www (I think it looks cleaner, anyway!)

After implementing bulk redirects, my score skyrocketed to 92/100.

![Ahrefs score of 92](https://d1d7p8ufhgz4ld.cloudfront.net/media/post_imgs/image_y8S5R6S.png)

<a id="removing-the-remaining-duplicate-pages"></a>

### Removing the remaining duplicate pages

I wasn't entirely done. I still had 27 pages that were flagged as duplicates. The issue was that the way I was doing pagination resulted in duplicate content. For example,

https://blogthedata.com/productivity?page1

Had a lot of the same headings, meta tags, and text as:

https://blogthedata.com/productivity?page2

I found a few solutions, but I didn't like them. I thought this would be an excellent opportunity to [implement infinite scrolling with htmx](https://www.jsolly.com/blog/implement-infinite-scroll-in-django-with-htmx/) so I could do away with pagination. You can reach more about that implementation in the linked post above, but the result was that my duplicate pages went down to ZERO!

<a id="conclusion"></a>

## Conclusion

Ahrefs is an excellent tool in your SEO toolbox. I resolved hundreds of errors that improved my site's SEO, accessibility, and performance. Take your site for a spin through Ahrefs and improve your website health!

October 26, 2022 in [Web Dev](https://www.jsolly.com/blog/category/web-dev/)

Updated October 26, 2022
