DEV Community

Cover image for SEO Bookmarklets | How to Improve your Link-Building with it | TOP 7 examples
Mykola
Mykola

Posted on

SEO Bookmarklets | How to Improve your Link-Building with it | TOP 7 examples

In today's marketing and SEO promotion situation, the question of how to simplify routine tasks when analyzing and checking sites is becoming increasingly important.

In my opinion, one of the most powerful resources for simplifying website-related work is such tools as bookmarklets.

In this article, I will explain what bookmarklets are, what they mean for link building, how you can quickly analyze sites with them and give 7 templates for bookmarklets that I use in my work.

Image description


What are bookmarklets and why are they used in SEO

A bookmarklet is a type of bookmark that consists of JavaScript code instead of a webpage.
Basically, it functions as a convenient bookmark button to perform a certain action.

Here is an example of what the bookmarklets look like, to make it clearer what I am talking about in this article:

Image description

Rather than directing the user to a particular URL, bookmarklets initiate specific scripts, acting as miniature applications or browser extensions.

These compact tools, also referred to as Bookmark Applets, or JavaScript Bookmarks, are compatible with all major browsers (Google, Bing, Firefox etc.)

Let's start with a basic bookmarklet that will help open the browser page in a new window

Just go to Bookmarks > Bookmark Manager > Add New Bookmark, add any bookmark name, and simply paste the following JavaScript in the URL field:

javascript:window.open(window.location.href)

Image description

As a result, you will have a new bookmarklet that will help you open the current tab in a new tab.

Below are TOP-7 of my own bookmarklets, which help me in website analysis and SEO work.

Below are the top 7 of my own bookmarks that help me with website analysis and SEO work.

For convenience, you can just try moving a piece of code to the Bookmarks Bar and a new javascript bookmark will automatically pull up for you

1.) Highlight Headings | H1-H6

javascript:void%20function(){var%20t=document.createElement(%22style%22),e=document.createTextNode('h1%20{%20outline:%201px%20dashed%20black%20!important;%20background-color:%20lightgreen%20!important;%20}h2%20{%20outline:%201px%20dashed%20black%20!important;%20background-color:%20%23ffc966%20!important;%20}h3%20{%20outline:%201px%20dashed%20black%20!important;%20background-color:%20lightblue%20!important;%20}h4,%20h5,%20h6%20{%20outline:%201px%20dashed%20black%20!important;%20background-color:%20%23ddd%20!important;%20}h1:before,%20h2:before,%20h3:before,%20h4:before,%20h5:before,%20h6:before%20{%20font-size:%2012px%20!important;%20margin-right:%204px%20!important;}h1:before%20{%20content:%20%22%20[H1]%22%20!important;}h2:before%20{%20content:%20%22%20[H2]%22%20!important;}h3:before%20{%20content:%20%22%20[H3]%22%20!important;}h4:before%20{%20content:%20%22%20[H4]%22%20!important;}h5:before%20{%20content:%20%22%20[H5]%22%20!important;}h6:before%20{%20content:%20%22%20[H6]%22%20!important;}');t.appendChild(e);var%20o=document.getElementsByTagName(%22head%22);o[0].appendChild(t)}();

With this script, you will be able to see all the H1-H6 tags that are on the site.

This will help you determine how well the text on the page is optimized without having to look at the HTML code.

2.) PageSpeed Insights Test

javascript:void(window.open(%27https://developers.google.com/speed/pagespeed/insights/?url=%27+window.location.href,%27_blank%27));

With this bookmark, you can quickly analyze page speed for mobile devices and desktops.
The analysis is taken directly from PageSpeed Insights, so now you don't need to keep a separate audit page.

3.) How many pages in index

javascript:location='http://www.google.com/search?q=%27+encodeURIComponent(%27site:%27+%20location.hostname+%27%20inurl:/%27)

This bookmark will tell you how many pages of the site are in the search engine index.

This can be useful for quick analysis of sites, but there is a significant disadvantage - if you use it very often, Google usually begins to suspect that you are a robot and requests a captcha.

4.) Highlight links (Sponsored, Follow, NoFollow)

javascript:void function(){var d,e,f,g,h,i,j,k,l,m,n;var o=document['getElementById']('supp-legends-5864');var p={};p['link']='#A7D189';p['nofollow']='#FDBD76';p['ugc']='#FAEBA6';p['sponsored']='#EB949D';var q={};q['link']='#86AF68';q['nofollow']='#DB913F';q['ugc']='#FCDCA9';q['sponsored']='#C9646E';d=document['getElementsByTagName']('a');for(e=0x0;e<d['length'];e++){f=d[e];g=f['attributes'];j=![];k=![];l=![];m=![];for(h=0x0;h<g['length'];h++){i=g[h];n=i['name']['toLowerCase']();if(n=='rel'&&i['value']['toLowerCase']()['indexOf']('nofollow')!=-0x1){j=!![];}if(n=='rel'&&i['value']['toLowerCase']()['indexOf']('ugc')!=-0x1){k=!![];}if(n=='rel'&&i['value']['toLowerCase']()['indexOf']('sponsored')!=-0x1){l=!![];}if(n=='href'){m=!![];}}if(m){if(j)f['style']['backgroundColor']=p['nofollow'];else if(k)f['style']['backgroundColor']=p['ugc'];else if(l)f['style']['backgroundColor']=p['sponsored'];else f['style']['backgroundColor']=p['link'];f['style']['border']='2px\x20solid\x20'+(j?q['nofollow']:q['link']);if(j)f['style']['borderColor']=q['nofollow'];else if(k)f['style']['borderColor']=q['ugc'];else if(l)f['style']['borderColor']=q['sponsored'];else f['style']['borderColor']=q['link'];f['style']['color']='black';f['style']['padding']='3px';}}if(!o){var r=document['createElement']('div');o=document['createElement']('fieldset');o['style']['border']='1px\x20solid\x20grey';r['setAttribute']('id','supp-legends-5864');r['style']['position']='fixed';r['style']['backgroundColor']='white';r['style']['width']='300px';r['style']['right']='5px';r['style']['bottom']='5px';r['style']['zIndex']=0x3e7;r['appendChild'](o);var s=document['createElement']('div');s['innerHTML']='Bookmarklet\x20by\x20<a\x20href=\x27https://supple.com.au/tools/highlight-no-follow-ugc-sponsored-links-bookmarklet/\x27>Supple</a>';s['style']['float']='right';s['style']['marginTop']='5px';s['style']['marginRight']='5px';var t=document['createElement']('span');var u=document['createTextNode']('X');t['appendChild'](u);t['style']['position']='absolute';t['style']['right']='5px';t['style']['top']='0px';t['style']['cursor']='pointer';t['style']['padding']='0\x204px';t['style']['backgroundColor']='white';t['onclick']=function(){r['parentNode']['removeChild'](r);};r['appendChild'](t);r['appendChild'](s);document['body']['appendChild'](r);}colorize=function(v){var w=document['createElement']('legend');w['style']['marginLeft']='5px';var x=document['createTextNode']('Legends:\x20');w['appendChild'](x);o['appendChild'](w);for(var y in v){var z=document['createElement']('DIV');z['innerHTML']=y;z['style']['border']='2px\x20solid\x20'+q[y];z['style']['padding']='3px';z['style']['margin']='10px';z['style']['backgroundColor']=v[y];o['appendChild'](z);}};colorize(p);}();

This command will help you find out what types of links are on a particular page
(nofollow, UGC, or sponsored)

PS: The bookmarklet will NOT be able to pick up nofollow links when they are deployed using the HTTP Header X-Robots-Tag.

5.) Image ALT tag checker

javascript:(function(){document.body.appendChild(document.createElement('script')).src='https://cdn.jsdelivr.net/gh/pauljadam/bookmarklets@master/images.js';var iframes=document.getElementsByTagName('iframe');for(i=0;i<iframes.length;i++) {iframes[i].contentDocument.body.appendChild(document.createElement('script')).src='https://cdn.jsdelivr.net/gh/pauljadam/bookmarklets@master/images.js';}})();

This piece of JavaScript will help you see what alt tags are prescribed for images on the site. It will help you check the optimization of images on the site

6.) Bad Content Checker

javascript:(function(){window.open('https://www.google.com/search?q="casino" OR "cbd" OR "gambling" OR "igaming" OR "essay write" OR "kasino" OR "888" OR "bet" site%3A%27+encodeURIComponent(location.href))})();

This bookmarklet allows you to view the pages of the site with "toxic" topics (we are talking about gray niches like gambling).

7.) Broken Images Finder

javascript:(function()%7Bvar ims%3Ddocument.images, brokenCount%3D0, brokenURLs%3D"", text, i%3B for(i%3D0%3Bi<ims.length%3B%2B%2Bi) if (! (ims%5Bi%5D.naturalHeight %7C%7C ims%5Bi%5D.fileSize > 0)) %7B %2B%2BbrokenCount%3B brokenURLs %2B%3D "URL: " %2B ims%5Bi%5D.src %2B "%5Cn"%3B %7D%3B text %3D brokenCount %2B " broken image" %2B (brokenCount%3D%3D1%3F"":"s")%3B if(brokenCount) alert(text %2B ":%5Cn%5Cn" %2B brokenURLs)%3B else alert("No broken images.")%3B %7D)()

Yeap, we're talking about doing an internal audit of the page via bookmarklet (no black magic)

Some other bookmarklet features

In this article, I talked about 7 different bookmarklets that can be used for link-building, SEO, or marketing work on websites. The possibilities of bookmarklets are not limited to this. They also have dozens of other equally exciting opportunities.
You can also put advanced search operators in the bookmarklets and search for specific keywords. Using some of them, you can do keyword searches, look at on-page optimization, or check the readability of the text.
Using different configurations, you can significantly reduce the time for analyzing donor sites in link building or preparing audits for the client.

Top comments (1)

Collapse
 
kevinsschmidt profile image
Kevin Schmidt

Great ideas!

I use this bookmarklet to save the current page to my external bookmark manager:
javascript:(window.open('https://bookmarkmanager.com/bookmarks/new?url=' + encodeURIComponent(location.href), '_blank'))()