Mike Ginley

Chrome DevTools Override For SEO

Share Article!

In This Post

TL;DR

  • Chrome DevTools Override can help illustrate changes to leadership and developers.
  • This tool is pretty limitless and can help anyone learn how to manipulate web pages.
  • The override feature allows you to save your changes so it doesn’t disappear when you reload.



SEOs have become very technical to the point where they can make technical changes themselves without a developer or programmer. It is an awesome trend that I continue to try and get better at so I can grow my skills. Sometimes the problem is that digital marketers and SEOs do not have permission to edit certain areas of the site. Many of us have CMS access, but we are often locked out of any CSS or JS files that are only touched by the development team.

Since I run into this issue a lot I was looking for a way to highlight certain changes to help speed up buy-in so we could get some technical optimizations pushed through. This led me to the local overrides feature in Chrome DevTools. Chrome DevTools is an awesome tool that has a lot of features that can help any technical SEO. The issue is that when you refresh, any changes you made disappear. Not anymore with Chrome DevTools override!

Google Chrome Local Overrides Video Walkthrough

Override Tab In Chrome & Enable Local Overrides

Setup Chrome Local Overrides
  1. Inspect the page you want to edit.
  2. Go to Sources in the menu at the top.
  3. Check the box ‘Enable Local Overrides’.
  4. Choose where you want to save the folder (I like desktop).
  5. Click Select Folder.
  6. Now you can go into the Network tab and select the file you want to edit.
  7. I like to sort by Doc, CSS or JS depending on what I need to do (below).
  8. You can go back into the Sources tab and see the files you saved and now you can edit them.
  9. Whenever you make an edit, ctrl + s to save changes so they continue after reload.
Select File For Local Override
Edit Local Override Code

How This Benefits SEO & Digital Marketing

Now that we know how to enable Chrome local overrides we can start changing the page and not worry about it disappearing when we refresh. We can also save the work for another time by storing the folder and bringing it back in following the process above.

The ways I have used this so far are to create a CTA through CSS and enable lazy loading to show the page speed impact by deferring offscreen images. This process can be pretty limitless.

This can be helpful with:

  • Core Web Vitals
  • Debugging CSS & JS
  • Graphic Changes
  • And Many More!

I will go over the lazy loading on Culver’s as well as add a CTA to show you how to manipulate and save the page.

Chrome Overrides For Core Web Vitals – Cumulative Layout Shift (CLS)

  1. Visit https://www.mikeginley.com/
  2. Enable local overrides like the above and save the folder to your desktop.
  3. Inspect in Chrome – Enable ‘Rendering‘ under ‘More Tools‘ (see image below).
  4. Scroll down and enable ‘Core Web Vitals‘, you will see metrics pop up in the top right of the screen (see image below).
  5. Currently, my CLS is 0! But we can break that to see how overrides can show us the impact of our changes.
    • I had a CLS issue caused by my logo. Find the class ‘hfe-site-logo-set‘.
    • Click on the associated stylesheet controlling the logo sizing.
    • Comment out the height & width with /* */ (see image below).
    • Save ‘ctrl + s‘.
  6. Hard refresh ‘ctrl + shift + r‘.
  7. The desktop was never bad, but mobile you can see is pretty badly impacted .18! (see image below)
    • Go back into the stylesheet and remove the comments and reload to see it’s back to 0!
Enable CWV & 0 CLS
Enable CWV & 0 CLS
Find CLS Issue
Find CLS Issue
Comment Out CSS
Comment Out CSS
Broken CLS
Broken CLS

Chrome Override For Page Speed – Lazy Loading

  1. Visit https://www.culvers.com/about-culvers.
  2. Enable local overrides like the above and save the folder to your desktop.
  3. Run a Lighthouse test in Chrome DevTools under the Lighthouse menu option.
  4. You will see the ‘Defer offscreen images that could save ~5 seconds.
  5. Go into the Network tab and save the doc file for overrides as we did above.
  6. Make sure when editing in the Sources tab to hit the pretty print icon brackets in the bottom left.
  7. Now we can search for every image and add loading=”lazy” (like below).
  8. After we do that hit ctrl + s to save the file locally.
  9. Now run Lighthouse again and you will see all the images that were flagged are now gone (like below, I left one to show that it works).
Add Inline Lazy Load
Before Offscreen Images
After Offscreen Images

Add a Call To Action

  1. Visit https://www.culvers.com/about-culvers (or any webpage).
  2. Enable local overrides like the above and save the folder to your desktop.
  3. Go into the Network tab and save the doc file for overrides as we did above.
  4. Go into the Network tab and save the CSS file for overrides as we did with the doc.
  5. In the Doc file add the HTML code below.
  6. In the CSS file add the CSS code below.
  7. After we do that hit ctrl + s to save the file locally.
  8. Reload, if you did this send me proof on Twitter!
HTML
<div class="container">
   <div class="callout">
      <h1 class="h1-callout">Who Is The Most Average SEO?</h1>
      <a class="btn-callout">It Me</a>
   </div>
</div>

CSS
.callout {
    position: relative;
    padding: 70px 20px;
    margin: 25px 15px;
    text-align: center;
    background-image: URL("https://www.mikeginley.com/wp-content/uploads/2022/02/mike-ginley.jpg");
}
.h1-callout {
    font: 'sans-serif';
    color: #ffffff;
     /*setting alpha = 0.1*/
    background: rgba(0, 0, 0, 0.3);
    font-size: 48px;
    margin-bottom: 10px;
}
.btn-callout {
    line-height: 40px;
    margin: 20px auto 0;
    color: #fff;
    background: #00825f;
    font-size: 22px;
    max-width: 600px;
    margin: 35px auto 0;
    padding: 10px 25px;
    font: sans-serif;
    text-decoration: none;
}

Additional Chrome DevTools Resources

This was just a very small sample of what can be done with the local overrides and Chrome DevTools. I am going to keep documenting new processes as I come up with them and I hope others do as well. The code for both can be way better, this is just a bandaid to better illustrate what is needed for the devs who are way better at this than me.

If you are new to using Chrome DevTools or looking for some additional tips, these are my favorites.

About Me

I am mainly using this site as a portfolio to create content that can help others in the industry. I have learned so much from people in this field and I want to do my part to help as well. I will continue to create processes and free templates that can hopefully help anyone in SEO and Digital Marketing. If there is anything you are looking for or have questions about please reach out to me on my Contact page or on Twitter!

Who To Follow

Interesting/smart accounts you should be following on Twitter:

Recent Articles

Popular Articles