---
title: 'Marker: Web selections to Markdown'
date: 2013-12-22 08:37
slug: marker-web-selections-to-markdown
categories:
- Code
tags:
- bookmarklet
- javascript
- markdown
- marky
- marker
---

This is a variant of my [Bullseye bookmarklet](/2013/07/30/precise-web-clipping-to-markdown-with-bullseye/) which takes a selection -- including headlines, links, and images -- and converts it to Markdown using [Marky](http://markdownrules.com/).

![](https://brettterpstra.com/uploads/2013/12/markerscreenshot.jpg)

It's not perfect, and still has some trouble loading on SSL sites (`https://`). Because you can select partial text nodes within an element, it occasionally has trouble putting the pieces back together. It also doesn't currently detect whether the selection contains hidden elements, so all elements present in the selection are converted (whether you know they're there or not). Overall, it seems to be working great.

The bookmarklet below loads from a [Gist](https://gist.github.com/ttscoff/8078727), so it will always run the latest source. I'll update it as I need to, and feel free to fork or just offer suggestions in the comments of the gist or by [contacting me](http://brettterpstra.com/contact/).

Install by dragging the link below into your Bookmarks bar. Drag a selection on a web page, click the bookmarklet and see the magic.


<div class="elWrapper">
<a class="bookmarklet" href='javascript:var markerShowFrame=0;(function(){var p=document.createElement("p");p.innerHTML="<strong>Loading&hellip;</strong>";p.id="loadingp";p.style.padding="20px";p.style.background="#fff";p.style.left="20px";p.style.top=0;p.style.position="fixed";p.style.zIndex="9999999";p.style.opacity=".85";document.body.appendChild(p);document.body.appendChild(document.createElement("script")).src="//d2z4mgf8zqkbu2.cloudfront.net/bookmarklets/marker.js?x="+(Math.random());})();'>Marker</a>
</div>


By default, the bookmarklet will take you directly to the raw HTML for the selection. If you'd rather load it in Marky's preview, you can edit the link and change `markerShowFrame=0` to `markerShowFrame=1`.

---

Brett is a writer and developer living in Minnesota, USA. You can follow him as ttscoff. This content is supported by readers like you. [More about Brett](https://brettterpstra.com/contact.md), including social links.

Copyright © 2026 Brett Terpstra. All rights reserved.
