If you find Alexa rankings really important, you might want to consider displaying your rank directly on your website by adding an Alexa widget.
A higher Alexa ranking is lucrative for advertisers and webmasters to take your website seriously. So why not take that opportunity to show the ranking directly on your website?
Displaying Alexa rank widget on your WordPress website is really easy. I will walk you through few different ways that you can add the widget to your website.
Follow this video guide to help you add the Alexa Rank Widget to your WordPress or Blogger blog.
If you are already familiar with Alexa and its ranking, you might want to skip the introductory section and find the code or plugins that you need for your website below.
For those who are still researching on the topic, let’s start with some basic introduction on Alexa ranking and if you should really consider adding the widget.
Table of Contents
What is Alexa Ranking – Alexa Traffic Rank?
Alexa ranking is a traffic rank position for a list of websites as published by Alexa. The website is owned by Amazon and presents itself as an information company that offers website information and analytics.
The company uses a sample of Internet users that it claims to be representative of all Internet users to estimate the ranks.
Alexa ranking, however, can be biased, and there are so many articles on the web claiming that the Alexa rankings aren’t perfect.
There’s certainly truth in such claims and you might want to understand how Alexa calculates rankings while taking them into consideration.
To solve problems around such issues, Alexa in recent years has introduced certified rankings to make the ranking more accurate. To have a certified rank webmasters, however, are required to subscribe the costly Alexa plans.
You can visit the detailed article from Alexa to know how the traffic rankings are determined.
Now that you have some idea of what the rankings can mean, let’s move onto how you can show the rankings on your blog or website adding an Alexa widget.
Alexa Rank Widget – HTML code
Adding Alexa rank widget is as simple as adding any text widget in WordPress. Alexa officially provides HTML code that you can add to your sidebar or any widget areas in your blog.
You can either display just your Alexa Rank or your Alexa rank including a count of the sites that link to your website.
Here’re the required HTML codes for both widgets.
1. Alexa Widget Showing Rank
Gist File:
2. Alexa Widget showing Rank with Count of Site Links
Obviously, you will need to change the WPism.com in above code snippets to your website URL.
To add it to WordPress, you will simply need to add a Text Widget in the required place.
Instructions: Go to Appearance > Widgets and drag the Text Widget from available widgets to the location you want to display your Alexa Rank. Copy and paste the above code in the widget.

Detailed Instructions to Add Alexa Widget with Rank
- From your WordPress dashboard, go to Widgets under Appearance section.
- Click on the Arbitrary text or HTML widget and add it to your desired widgets section.
- Copy and paste the above code in the HTML widget.
- Change the URL in the above code to your own website URL.
- Click on Save and your Alexa Rank Widget should now appear on your Website.
Adding Alexa Widget with WordPress Plugins
That previous method of simply adding HTML codes should be the best option, but if you are looking to add the Alexa widget using plugins, there are few plugins that can help you with it.
I will cover one of the plugins that seem to be frequently updated and used by a number of people to add the Alexa widget.
Alexa Rank Widget WordPress Plugin

This simple widget just allows you to add the Alexa rank widget in your sidebar. All you have to do is drag the widget to the sidebar or footer you want to display and fill your website URL.
The plugin provides two options to display the Alexa widget
- Square – Button (120 x 95)
- Vertical – Vertical Banner (120 x 240)
Instructions: Once you download and Install the plugin, go to Appearance > Widgets and Drag the Alexa Rank Widget from the available widgets.

Can the Alexa widget improve your ranking?
One important part of this article, before we conclude, is if displaying the Alexa widget can improve your ranking.
I have seen several webmasters displaying their rankings on their blog, but I don’t have a definite answer if it actually impacts the ranking. I have seen blogs with good rank using the widget, and I might be biased to suggest from such pieces of evidence.
Alexa in one of its blog post has mentioned that installing an Alexa widget to improve your rank is actually a myth and that the widget is not used to measure traffic.
One thing that I have learned from my experience is that it actually can influence your ranking if people are clicking on your widget and landing on to your Alexa page, such as WPism.com page on Alexa.
Although it won’t make your ranking certified, Alexa can have more data to have some valid estimates for your ranking. Again, I would recommend going through how Alexa calculates its ranking in details.
Why is my Alexa Rank decreasing?
I get questions about decreasing Alexa rank all the time. Alexa Rank is mostly based on your website traffic and if you see a drop in your Alexa ranking, it should also suggest that your website traffic has decreased recently. It might also mean that your competitors are gaining more traffic than you.
Few other situations why your Alexa rank could be dropping;
- Many of your website users are not using Alexa toolbar. Alexa uses data from its toolbar users and it might be possible that your website has a significant audience that aren't using the Alexa toolbar.
- Other websites, mostly your competitors should have stepped up in traffic or getting more visitors with Alexa toolbar installed on their browsers.
- In few situations, your website might not have been favoured by recent changes in Alexa's algorithm.
Final Thoughts on Alexa Ranking
It's true that Alexa ranking cannot be taken as authoritative for website rankings and although it might help you to inform about website's position broadly, it isn't wise to use the data for website comparisons.
Displaying an Alexa rank widget on your website can be something for you to decide but as for my suggestion and provided that you have a good ranking, it can surely be a plus point for you to display the rank on your website.
As Google Page rank has been discontinued, we are only left with few public ranking options that are reliable. Alexa and Compete Traffic ranks might be the only options that we have today.
Do you use Alexa ranking widgets? I would love to hear your view about Alexa rankings in the comments below.
Alexa Widget Review Summary
It's really easy to display Alexa Ranking widget on your website using the custom code provided by Alexa or using the WordPress Plugins.
84 Responses
Thanks for the Share..
Thanks. I was able to use the info provided to display Alexa ranking on my site. For WordPress users who are using the HTML widget use the center tag to centralize the widget.
Thanks for the alexa widget. It helps improving your alexa rank
Very nice content. I’m a new blogger in the blogosphere. my website is still very young and I want to know how I can improve my site traffic. Thanks
thanks for the tips mate 🙂 have added the same on my blog. do have a look 🙂
Hi Vishal
Thanks for the comment. Would appreciate if you could comment with your own name – we are all human after all!!
Your post is really good!
hello there..i just added alexa rating to my blog but its showing no data..plz have a look at my blog m i missing something..
Hi Adam,
I just checked your blog and I can see the Alexa widget! Try refreshing your page or visiting from a different browser.
I don’t know Why My site is not showing alexa rank. I am using your code. Please see my site theexplode.com. I applied the code at footer side.
Because “The Alexa rank widgets were retired on October 26, 2016.” but you probably already know it cause you posted this a few month ago. Anyway this answer is for others.
Thanks Pradeep, just added the widget on my site too can’t wait to see my alexa rank get better!
Hi Rukundo,
Keep publishing the great content.. It will definitely get better over time!!
All the best.
I fill so happy with this post as if am the only one find it useful.
I have added It to my blog…. Thanks!!!
Works like magic. Thanks
Got the solution thanks for the guide. Just placed alexa widget on my blog
Can alexa rank be shown on the free wordpress site also? As i have a free wordpress site, and i have added the html code of alexa rank in text widget, but nothing is shown there. Can anybody help me out?
Hi Shivam,
I have seen other WordPress.com users this issue. I don’t think WordPress.com allows external Javascript on their website. Here’s what I have found on their official pages:
“Users are not allowed to post JavaScript on WordPress.com blogs. JavaScript can be used for malicious purposes. As an example, JavaScript has taken sites such as MySpace.com and LiveJournal offline in the past. The security of all WordPress.com blogs is a top priority for us, and until we can guarantee scripting languages will not be harmful, they will not be permitted.
JavaScript from trusted partners, such as YouTube and Google Video, is converted into a WordPress shortcode when a post is saved.”
I have put the html tag on my blog widget area but it shows link only not stats. Pls check my site-
https://bengaliworld.wordpress.com
Hi Prasenjit,
The widget has Javascript code, and I guess WordPress.com doesn’t allow external javascript on their pages. See the above comment for more details.
I read somewhere that the Alexa widget does not support https sites. Please advise.
Hi Alex,
That’s true as of now – Alexa’s official website mentions that their widgets do not support https.
Thanks so much for the confirmation Pradeep. Awwww it’s so unfortunate I cannot use that on my site 🙁
you can
just pull the data with php.
if you use wordpress:
first install PHP code plugin, this will allow you to insert php code anywhere on widgets area.
then inside the php widget insert this code:
<?php
$source = file_get_contents('https://data.alexa.com/data?cli=10&dat=snbamz&url=yoursite.com');
//Alexa Rank
preg_match('/\/si’, $source, $matches);
$aresult = ($matches[2]) ? $matches[2] : 0;
//Alexa Sites Linking in
preg_match(‘/\/si’, $source, $asli);
$alinksin = ($asli[1]) ? $asli[1] : 0;
?>
don’t forget to replace “yoursite.com” with your domain
This way you don’t show your ranking but you get the benefits and improve your ranking, it has the same effect as the widget.
<?php
$source = file_get_contents('https://data.alexa.com/data?cli=10&dat=snbamz&url=yoursite.com');
//Alexa Rank
preg_match('/\/si’, $source, $matches);
$aresult = ($matches[2]) ? $matches[2] : 0;
//Alexa Sites Linking in
preg_match(‘/\/si’, $source, $asli);
$alinksin = ($asli[1]) ? $asli[1] : 0;
?>
It’s really Helpful Post. Thanks
Thanks for the tips. we are working very hard to create a social networking site, hope the tips will help us to increase the alexa ranking fast.
thank for a share this tutorial because i need this. Now i don’t open to alexa website to see my ranking
Looks nice on your site Gaurav 🙂
I’m going to instal it rightaway!
Is there any permanent way to increase rank in alexa?. Advertiser generally check this tool and believe too much on alexa”s rank. And we publisher facing trouble.
Hi there, I tried using this on my client’s website but it’s not working. The “My Alexa Ranking” title shows up but the actual rank doesn’t. Can you help me please?
Useful Information . Thank you.
Finally I got solution from here,thank you very much
Hi,
Thanks for sharing this post, We are having Regular posting in our blogs, but still we are facing to increase alexa ranking, any other short cut ways to increase alexa ranking
Thanks
Thanks for sharing.
I think that even if we add alexa widget to our blog it won’t help up decrease our ranking, it’s just a type of showing your visitors and advertiser the real stats of your blog.
Are you agree with me Mr. Pradeep Singh ?
Thanks for the share.
but when i put the alexa HTML code in my website through blogger, it doesn’t appear in the website, i have also a similar problem, any HtML code like banners doesn’t appear too.
I tried to change the template, but no results.
For information : i don’t use Adsense in my website.
Thanks in advance
Very useful article but if your site has not developed on word press how to add this widget on your website.
Hey,
I have already added the html code in the sidebar widget area but nothing is displaying in our page.
please advice us
how to get alexa rank to my website?
Thanks to providing tips for create alexa widget. These tips are really good and easy to understand.
Thanks again
Does anyone know how to stick on Osclass sites?
Very useful.thanks for sharing your knowledge with us
Thanks for sharing! Love the Alexa toolbar, so simple to see your rank!
Thanks for the share. i put the alexa HTML code in my website it’s working.
hope the tips will help us to increase the alexa ranking fast.
thank you very much this is very helpful post for me …
Nice Post, how can i include a country rank as well. check my blog please.
I was looking for the alxea rank code for widget.Not plugging.Any thank you very much for the good and informative post..
Such a nice information to improvise alexa ranking. Its working fine for me.
Thank You!
Thanks
I Realy Need Of Second One 😉
Cheers 😉
Really good Article.
if adding alexa widget more than one time then what happened?
Such a nice way to improve Alexa Rank of website/blog.
Thanks for d tutorial. I just implemented it in Brainology
please check my site it is not showing the widget in blogger telugumve.blogspot.com
Hello,
Thanks for sharing the information. I was new to blogging and I had a question. Alexa does really matters in website rankings? Please guide me with your valuable suggestion.
I think having Alexa Ranking widget on my website is a plus even if it does not affect my rankings in reality. I say this because it helps one measure if their traffic generation techniques are yielding substantial results. @Poster, Thanks for this.
Thanks for this awesome and helpful post at last I have now integrate the widget in my site.
keep it up.
Thanks for providing valuable info because of the widget the ranking of mine website ranking improved.
Really amazing explanation and very nice article …. Thanks for sharing this!! 🙂 🙂
Hey thanks for the great article. I’m new to blogging andI was having doubts whether adding the alexa widget would improve the ranking or not, not any more.
I’m adding the alexa widget right away. Thanks for the plain and simple explanation.
Hi Pradeep! alexa rank is really important and the tips you have provided are very helpful. I will use these tips to get a better rank for my site.
Thanks buddy.i just thinking about alexa code to input on my blogger blog.and i finding your article.such a beautifull article.nice job.
I had never noticed before about Alexa. But by reading this, I’d probably try to learn it.
Thanks a lot, I am searching on Internet – how can I increase my site’s Alexa rank, finally found it here() with full guide. keep sharing.
this is the awesome post i was looking for something like that thanks bro i will try alexa widget on my website topbestlist.in
It’s not working anymore. Is there any new way to add alexa rank in wordpress blog ?
Hi Tejasvi,
I know the widgets have been officially retired but the code still works for me. See this screenshot – http://imgur.com/a/Tv4DF
Thanks Pradeep, for informative article.
is alexa rank is really matters ?
what are the performance metrics so we can trust on alexa rank ?
Arvind
i think alexa widget is not working anymore..! according the latest update by alexa, they retired the alexa widget in may 2016
Great info . But I have some questions; For about one week my site is on exactly same Alexa page rank, is this normal? Secondly I have been making some backlinks (mostly from social media sites and forum sites) to my website for two months, but they did not appear yet? I wonder if Alexa did not count those as backlinks or bots did not visit that pages?
Thanks in advance…
Very good information !
-Arvind
Thanks, rather than using a plugin to insert some code dynamically and made it load few miliseconds more, typing code in widget is more good idea.
My site is a self hosted site I am trying to add widget to site but it is only showing the title of the widget not the ranking . Please advice I followed all the steps as shown above.
I will try, because I am looking for alexa widget on its oficial web is not available.
Thank you.
Great tips i will follow these tips to increase my website Alexa Rank Thanks!! Good job.
Thanks for your tutorial. I have tried using code /widget but not display . why not show alexa widget.
I don’t know Why My site is not showing alexa rank. I am using your code. Please see my site banananews.pk . I applied the code at footer.
very useful post
Great one. Finally found an article on Alexa ranking. Thanks for it. Keep sharing.
Yes, Alexa rank plays a very important role to get rankings to your site. Not only ranking but get more visitors. I like the way of your explanation. It will definitely helps me. Until I studied this post I really don’t know ” more visitors- good Alexa rank.”
Hi Pradeep,
I guess Alexa Rank Widget has been retired. Is it right? If it is, then is there any workaround for the same?
Thanks.
Hello, Nice tips to improve alexa rank. By appling some of the above mention tips I have improved my alexa rank. Thanks for sharing.
Thanks Man, You are awsome.
Looks great! i will install it!
Comments are closed.