How to highlight and copy text on sites that block it
Every now and then I come across sites on the Internet that prevent you from copying some or all of the text displayed to the clipboard, or even selecting it in first place using the mouse or keyboard.
I noticed this on a bank's site recently for example where I was not allowed to copy the bank account number to the clipboard.
This guide looks at methods to overcome the limitation put in place by websites on the Internet. But first, why do sites implement these restrictions in first place?
While reasons are provided by companies and individuals who implement the functionality on their web properties, the most likely reason is some form of copy protection.
Method 1: Turn off JavaScript
Most websites use JavaScript to block mouse functionality. If you turn off JavaScript on the site temporarily or even permanently, you will be able to copy text displayed on it using the mouse.
Some websites rely on JavaScript on the other hand which means that you may run into issues doing so. Some may even refuse to display at all when JavaScript is turned off.
- Firefox users can press F12, then F1 to open the preferences and check the disable JavaScript on the page that opens..
- Chrome users can disable JavaScript in the Content settings: chrome://settings/content
- Internet Explorer users can turn off JavaScript in Internet Option > Security > Zone > Custom Level > Active Scripting
- Opera users can disable JavaScript under Websites in the Opera settings: opera://settings/
Extensions like NoScript can be useful in this regard as they block the execution of scripts as well.
Method 2: The source
Another option that you have is to display the source code of the website you are on. Since it is displayed in a plain text editor it is possible to copy anything from it without restriction.
Simply press Ctrl-u while you are on the site to display its source code. This works in most browsers including Firefox, Chrome and Internet Explorer.
It is still necessary to find the text or content that you are looking for in the source. Use Ctrl-f to jump directly to it.
There you may also find links to images and other contents that you could not save or copy.
Method 3: Extensions and scripts
The third and final option is most suitable if you encounter sites regularly that prohibit right-click use or text copying when you are on them, and if the methods outlined above don't work or are not really suitable.
- Absolute Enable Right Click & Copy for Firefox to remove copy text protections on sites, enable right-click actions, and disable annoying prompts.
- RightToCopy for Chrome offers similar features.
You find numerous extensions for these two browsers that remove annoyances on websites.
On Chrome something that works for me is to do ctrl+a then ctrl+c and paste onto a word doc. Then just copy and paste what you want from there! More useful if you want to copy ALOT of stuff because.
Chose the print page option and copy from the print preview box. It is easy, and it works!
save as pdf and enjoy
the problem is that some sites won`t loading when you disable JavaScript
Thanks bro , you helped me a lot 😇
thanks for all the help but it still doesn’t work for me and i’m extremely desperate to copy and paste for some really important images i need, could anyone help?
I use Pocket – https://getpocket.com – to save web pages (rather than bookmarking them). When I encounter a page that won’t let me right click or highlight text, I save it to Pocket. Then I go to my Pocket list, open the link, and copy it from there. Don’t click on ‘View original’ or you’ll be back where you started. Just copy from the cached page. Works for both text and images.
“JavaScript” isn’t even in the settings for Chrome.
Worked on Chrome. Thx a lot !
Omg! I tried to disable javascript but site didnt run so i had to use the extensions RIGHT TO COPY. and it worked. thanks so much.
Any luck on a Chrome workaround? I used to use Firefox, but it bogged both my systems and crashed randomly, no matter the update. So I switched and still getting used to it.
WHAT WILL WORK WITH BRAVE BROWSER?
i tried to use right to copy and it worked for my brave. note all extensions of chrome can run on brave.
right to copy
https://chrome.google.com/webstore/detail/absolute-enable-right-cli/jdocbkpgdakpekjlhemmfcncgdjeiika/related?hl=en
Use a proxy website that allows you to disable JavaScript before opening the site that s of interest to you. Just go to your search engine and find a free proxy website.
Thank a lot, The info was very helpful.
As always Martin, I learn more useful, how-to information on your site than almost any other by far overall, for Linux, and Windows; which I do pass on to my customers whom I do computer work for when the occasion presents itself. I also want to express my gratitude for your years of sharing your experience and knowledge. I have the utmost professional respect for people like yourself who do what they do for the love of it.
(please feel free to leave the following out if it doesn’t fit the article)
I do try to support my top sites as money allows as much as I can. I will continue to follow the sites, yours is on my top 5, that I read faithfully before most.
thank u very much
Extensions above are not working.
Use itï¼ï¼ï¼ï¼ï¼ï¼
Enable right click
https://chrome.google.com/webstore/detail/enable-right-click/gpeddepmnbmkjfnhifmggnjdggibjjkf/reviews?authuser=1&hl=en
body, html{
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
The best way is open the website in Opera and right click to select “save to PDF”. There you can select all the texts you need and copy. :)
Used the Mozilla / Firefox option – Worked Perfectly – Thanks!!!
I tried all of this things, but nothig works.
Paste Pro extension in Chrome does it all .
Thank you..
thank you sooooooooooooooooooooooooooooooo much <3
One word, LEGEND!
thx helped me a lot
Hello, I have a browser made by Javascript disabling copying from it, how can I copy it. It’s not among the browsers you listed above. Can you help please
The turning off javascript didn’t work for me…
RightToClick Chrome extension worked perfectly for me..
Thanks so much for this. It saved me from taking several screen shots.
Sometimes, if you can highlight the text then you have the option to search Google for the text you’ve highlighted and then click back into the searchbar and your search history should pop up with the last searched item being the text you’ve highlighted on the previous website.
it works , thanks
Wastage of time.. literally of no use.
Make a bookmark and use this as URL:
javascript:void(document.oncontextmenu=null); document.body.onselectstart = function() {return true;};
Tested with Chrome.
Thanks a lot…
Thank you Martin. It totally helped me for my project work.
thanks brotha!
Thanks a ton!
This method worked for me on chrome:
Try to print page, then you can select the text in the preview window.
Thanks alot. Finally this worked for me to copy some text on page . You saved my day
Thanks for this tips.. only way for me to copy some info on a page :D
in firefox one can use “reader mode” like described here http://useitsmart.com/copy-text-site-blocks-coping
I used to use the righttocopy extension but the person took it off. What else can I use for an extension on firefox to copy and paste sites that have disabled it?
Hi Martin,
Nice article and it is very useful!
This is priceless! Thank you all
I *really* hate it when sites do this to me. Any web publisher who is attempting to plagiarize will already know how to bypass this, and anyone who doesn’t can search for a solution in 30 seconds. All it serves to do is make me feel like an idiot when all I’m really trying to do is select a few words to use as a search term so I don’t have to manually type it. I ended up using RightToClick as an alternative to jumping into the inspector every time.
Thanks Man !!!
Thank you very much!! Really helpful and saves me a lot of time.
u can try reader view mode in firefox its easy
There are web pages that disable that feature.
Method 3 for Chrome did it for me.
Thank you for helping me to do my job better and more efficiently. God bless.
Thanks Bro
In search machine or anywhere click right on website and choose print and you will able to copy
Yes, you can use the print screen to copy! I was so happy to discover this today and offer it as a comment.
You can use GT Text (softocr.com). Is a totally free program for windows. And just press ALT+C and with OCR you have the blocked text.
Ctrl + U :) Thanks!
How to copy content of a website that won’t accept the disabling of Javascript?
Disable JavaScript in the browser. Or, save the page, and copy it then.
Thanks! Method 1 worked for me!
Thanks a lot! Method 1 worked. :D
thanks..really appreciate it! good job!
simply use faststone capture to copy, print or save anything you want to on any site / desktop anywhere …no hassle no problem no magic…easy easy
Thanks for the tip about “Ctrl-u.” It may come in handy sometime.
What bothers me the most are the pages where it is not possible to use bookmarklets in the kind of “Printwhatyoulike” or “Printliminator” to create pdf-files to archive.
All these methods don’t help in this case.
Thanks for the tips anyway.
Reader View obviates the use of Printliminator.
Basically a bookmarklet should always operate correctly if javascript is not disabled. But there are some pages which have been crafted in such a way that they cannot be scanned from another site, indeed. I don’t know how they manage but I’ve noticed it, very few times, when saving a page with printfriendly.com or a dedicated bookmarklet. Also, some pdf-makers don’t handle https pages.
Change browser View/Page option-Style …. to “No Style”
Also, often it is only the on screen visual ‘highlighting’ that is disabled — you can still highlight/copy text as normal with mouse/keyboard… you just can’t see the color/shade change on the text you select.
In Firefox shift+right click will always get the default menu. I learned this by accident when I was trying to make shift+right click do something and it just wouldn’t work. Not sure if Chrome has something similar.
I learned something. Interesting. Many application shortcuts are unknown by many users. Shift+Right_Click on Firefox (at least) always brings up the default menu. Good to know.
That’s really good to know. Great tip!
One method that has never failed me is to take a screenshot.
Works, unless you need the text and not the information. Thanks!
There is a nice tool to convert images to text : Free OCR from http://www.paperfile.net/
Does a great job, but needs .Net v2 and the Tesseract language pack for the language used.
You can also save the page as a PDF, and open that one in PdfXchange viewer, which in recent versions has a very efficient and nicely working ocr tool to export selected text.
Besides, using Firefox, i often use an addon that saves a copy of the page as it is ,apparently without scripts. From that, you can just copy whatever you want.
Find it at https://addons.mozilla.org/en-US/firefox/addon/mozilla-archive-format/?src=search
I’ve never bothered to use it, but its been in my marklet folder on my toolbar for about 2 years
javascript:function%20kill(d){d.onmousedown=d.onmouseup=d.oncontextmenu=d.onselectstart=d.ondragstart=function(){return%20true;};}try{kill(document);for(var%20j=0;F=frames[j];++j)kill(F.document);}catch(e){}
Reenable Right Click.
javascript:/*Anti%20No%20Right%20Click.%20Copyright%20(C)%20CodeHouse.com,%202004*/function%20kill(doc){doc.onmousedown=doc.onmouseup=doc.oncontextmenu=doc.onselectstart=doc.ondragstart=function(){return%20true};if(window.releaseEvents){releaseEvents(Event.MOUSEDOWN|Event.MOUSEUP);}}onerror=function(){return%20true};kill(document);if(frames.length){for(i=0;i<frames.length;++i){kill(frames[i].document);}}else{kill(document);}
didn’t work to enable copy on
1. Google news https://news.google.com/?hl=hi&gl=IN&ceid=IN:hi
2. on basilisk and on palemoon http://tvwiz.in/app/app/channelBrowse/69 (on ff copy is already working o this page 2, but these 2 browsers are working on ff code, so it should work)
when you say something earthbreaking and make us run a script, and it doesn’t do what you said it would do, we use to think whether you are a hacker and whether your said script has stolen our data from browser?
be careful.
Here I’ve bundled two scripts found on the Web into one and built a bookmarklet called whenever a page refuses right-click and/or refuses text copy. I haven’t yet encountered a page where the bookmarklet would be ineffective. Works with Firefox, elsewhere I don’t know.
Bookmarklet’s script : http://pastebin.com/tYiV0UYZ
Copy the script, create a new bookmark, give it as url the script, as name as you wish, call that bookmark on those naughty pages (for those who ignore what a bookmarklet is)
another method I use,
just create a new bookmark, name it as you want and paste this line as URL :
javascript:void(document.ondragstart=document.body.ondragstart=null,document.oncontextmenu=document.body.oncontextmenu=null,document.onselectstart=document.body.onselectstart=null,document.onclick=null,document.body.onclick=null,document.onmousedown=document.body.onmousedown=null,document.onmouseup=document.body.onmouseup=null,document.onbeforecopy=document.body.onbeforecopy=null,document.onbeforecut=document.body.onbeforecut=null,document.oncopy=document.body.oncopy=null);
usualiy it works well with Firefox, I don’t have to disable javascript, just send the instruction to re-enable features supposed locked on the Web page
That use of bookmark is the best. Thanks
Sometimes pressing shift, ctrl or alt is enough.
dude it worked LOL control shift that is…you rock!
Martin, Thanks for again a really interesting to read and easy to understand article.
Niks is mention this above but not answering all of main question so here is main question to you Martin:
The only question your article leaves me with is or the above mentioned programs and also your guide
to the actions I can follow also works with saving pictures?
I often encounter sites who forbid me to save a/the picture(‘s) from there website so I am wondering
are there outer methods for saving pictures from those sites?
Or is this method working whit who I can save pictures from websites who forbid me to do so?
You can always view *all* images used in a webpage (except those displayed by plugins like Flash) in Firefox by choosing Tools -> Page Info -> Media tab. This will also allow you to save any images.
Yes disabling JavaScript will do that as well, provided that the images are still displayed after you disable it.
Disabling javascript can also help in copying/saving images where right click is disabled . I use this method to download images from instagram .