Title: Bookmarklet: Add URL to Links
Author: Alex Kirk
Published: March 2, 2015

---

# Bookmarklet: Add URL to Links

March 2, 2015

A quick one: If you need a website text for copying it as plaintext, you can prepare
this by using this bookmarklet:

[add URL to links](https://alex.kirk.at/2015/03/02/bookmarklet-add-url-to-links/(function(){var%20a=document.getElementsByTagName("a"),i;for(i=0;i<a.length;i++)a[i].innerHTML=a[i].innerHTML+" ["+a[i].href+"]";})();?output_format=md)
(
drag to your bookmarks bar)

[add URL to links](https://alex.kirk.at/2015/03/02/bookmarklet-add-url-to-links/(function(){var%20newcss="a:link:after, a:visited:after { content:\" [\" attr(href) \"] \"; }";if("\v"=="v"){document.createStyleSheet().cssText=newcss}else{var%20tag=document.createElement("style");tag.type="text/css";document.getElementsByTagName("head")[0].appendChild(tag);tag[(typeof%20document.body.style.WebkitAppearance=="string")?%22innerText%22:%22innerHTML%22]=newcss}})();)
with CSS: text cannot be copied
 (drag to your bookmarks bar)

[Web](https://alex.kirk.at/category/web/)

Read this next

[Bookmarklet: Add URL to Links https://t.co/0kd9g2CaXm](https://alex.kirk.at/2015/03/02/bookmarklet-add-url-to-links-https-t-co-0kd9g2caxm/)

### Leave a Reply 󠀁[Cancel reply](https://alex.kirk.at/2015/03/02/bookmarklet-add-url-to-links/?output_format=md#respond)󠁿

Only people in [my network](https://alex.kirk.at/friends/) can comment.

This site uses Akismet to reduce spam. [Learn how your comment data is processed.](https://akismet.com/privacy/)