How To Disable Right Click On WordPress Blog And Blogger

Disable Right Click Without Plugins

Hello Friends In this post, I will tell you how to disable right click on your WordPress blog and bloggers. Here I will talk about both wordpress and bloggers platform, if you have created a blog, then there are many image, text that has been created by very hard work. And if someone uses your blog’s content, text, images, and you use it somewhere else, you will not even know and your content will be used on any other blog, or it may be possible to copy that image. Make great changes and use it.

Disable Right Click Without Plugins

Today the content has become very easy to steal from any website. When go to any blog or website you can right-click and save by copying the save image or text. So today I will tell you how to keep your blog content safe by right click disable.

Here I will tell the tricks of both wordpress and blogger, giving the copyright of all right reserved blog in the footer does not stop copy of image and text:

For WordPress Blog Disable Right Click :

Anyone can click on the right word in the wordpress blog and view your source code so that they can know the name of the theme of your blog or which plugin you are using.

If you are a wordpress blogger then you have two options disable right click –

Step by Step 1:

  • Login to your wordpress dashboard
  • And go to the editor in the Appearance option.
  • Here you have to open the header.php file of your theme.
  • In this you can copy and paste this code into the <head> … </ head> section.
<script language = JavaScript> var message = "Function disabled!"; function clickIE4 () {if (event.button == 2} {alert (message); return false; }} function clickNS4 (e) {if (document.layers || document.getElementById &&! document.all) {if (e.which == 2 || e.which == 3} {alert (message); return false; }}} if (document.layers) {document.captureEvents (Event.MOUSEDOWN); document.onmousedown = clickNS4; } else if (document.all &&! document.getElementById) {document.onmousedown = clickIE4; } document.oncontextmenu = new Function ("alert (message); return false") </ script>
  • Save

right click disable

Now you will refresh your blog disable right click.


Do not make any changes to this code otherwise error will occur. And when someone right clicks on your blog then there will be a small message in the use browser: “Right click function disabled” If you want to send another message, change it accordingly, or if you do not want any message aye then this message will be sent to this Remove from the line.

var message = "Function disabled!"

Step 2:

To protect your content from copying in WordPress blog, there are many free plugins like wp copy content, wp content copy protector, you just install and activate it and they will start working.

For bloggers:

If you have created your own blog on blogspot, then right-click on your blog can see the source code and you can copy and use the code of the widget you have used.

How to disable right click in Blogger:

Step by Step:

  • Login to Blogger dashboard.
  • Now click on Layout> Add Gadget.
  • Now select the HTML / javascript widget.
  • And paste this code and save it, now your blog is safe.
script language = JavaScript

// Disable right click script - By
var message = "Disable Right click";


function clickIE () {if (document.all) {(message); return false;}}

function clickNS (e) {if

(document.layers || (document.getElementById &&! document.all)) {

if (e.which == 2 || e.which == 3) {(message); return false;}}}

if (document.layers)

{document.captureEvents (Event.MOUSEDOWN); document.onmousedown = clickNS;}

else {document.onmouseup = clickNS; document.oncontextmenu = clickIE;}

document.oncontextmenu = new Function ("return false")


/ script>


These are all tricks for the blog and website, but if you do not use code editor or you have nothing knowledge about coding then you simple use wordpress plugin. But in the blogger you can use code because blogger don’t have any kind of plugins. When you have do this then, it will not be able to copy the visitor.

If you like this post or this post is helpful for you then please share on social media with your friend. Please subscribe our blog for latest blogging and wordpress tutorials.

About Manish Singh

Hey Mania, Welcome to the Techmenia! I’m Manish Singh, a blogger from Varanasi, UP, India. Here at Techmenia, I write about latest news on technology and science, and also making money online. We also have some knowledge about Health & fitness. So, Stay with us and Subscribe our blog via email don't forget latest update.

View all posts by Manish Singh →

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.