Including email addresses on Web pages

Angry Tiger
Photo by claudiogennari

Not unreasonably, if you have a web-site you will want to include your email address so that potential clients can contact you. Unfortunately, if you have your email address in plain view on a webpage without encrypting it in any way then it is inevitable that you will get a huge amount of spam to that address.

There are several ways to address this problem. One is to use a contact form with Captcha text, but that requires some knowledge of programming. Perhaps the simplest is to replace bits of the address so that a human can read them and work it out, for example:

yourname -at- domain -dot- com

That works, but does require the enquirer (a potential client, remember) to type the address in by hand. We don’t want to make things any more difficult for them than we need to.

Another way, which does result in a clickable link on the page, is to use codes for the characters of the address rather than actually typing it in. For example, the code for the letter ‘y’ is 121 so including y on a webpage will tell the browser to display a letter ‘y’. A simple tool to convert the whole email address is at
Type in ‘’ and get back:


Include that in your web page as an html link:

<a href=”mailto:

and on your web page it comes out as a normal, clickable link, so there is no chance of your potential client mistyping it, but it is harder for spammers to read.

This isn’t foolproof – it would be quite practical for a spammer to write a program to get around it – but it is just about making your address more difficult to harvest than someone else’s. Basically it is like the man chided by his friend for tying his shoelaces when they see an approaching tiger – his friend says “you can’t outrun a tiger” – he replies “I only have to outrun you”.

Originally published online January 27, 2010, and in SIDelights (Society of Indexers Newsletter)

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s