Agile Web Development

Build it. Launch it. Love it.




CipherMail provides a safe alternative to the mail_to helper by hiding mailto links from e-mail harvesting bots. The generated output is completely obfuscated by a 1024 bit random key. They keyword is stored on the server, so it is never revealed to the client. Processing is performed on the server-side via an AJAX request and the decrypted redirect is returned to the client, opening a mail composer window… just like normal mailto link.


  <%= ciphermail_to "John Smith", "" %>

Note: A new key is generated every time you restart your web-server.

      If you'd like to manually generate a new key, simply run:
      ruby ./script/runner "CipherMailSetup.genkey"

That’s it! Have fun, and feel free to send me questions or comments.

Copyright © 2007-2009 Michael Behan aka "JabberWock" (djether /AT gmail /DOT com) Released under the BSD license


License BSD
Rating (20 votes)
Owner Jabberwock
Created 23 July 2007


  • andrew
    24 September 2007

    A little less convoluted, maybe?

    I think both your solutions will fail when spammers start processing javascript or using something like:

    blah, the battle rages on.

  • Avatar
    Felipe Giotto
    1 October 2007

    Good post, very easy to use, and not so easy to break! Thanks! I'll store this in my recommended plugins list!

  • Avatar
    3 October 2007

    Thank you both for your feedback :) It is always appreciated!

  • jc
    30 March 2008

    seems the site has disappeared. ive googled but cannot find this repository or code anywhere else. any place i can still find it?

Add a comment