Try Tuts+ Premium, Get Cash Back!

10 Rare HTML Tags You Really Should Know

Web developers these days are often expected to know and work in multiple languages. As a result, it’s tricky to learn everything a language has to offer and easy to find yourself not utilizing the full potential of some more specialized but very useful tags.

Unfortunately we haven’t been tapping into the full potential of these more obscure HTML tags as of late. But it’s never too late to get back into the game and start writing code that taps into the power of some under-used tags.

Here are ten of some of the most underused and misunderstood tags in HTML. While they might be less familiar, they’re still quite useful in certain situations.

1. <cite>

All of us will be familiar with the <blockquote> tag, but did you know about <blockquote>’s little brother <cite>? <cite> allows you to define the text inside of the element as a reference. Typically the browser will render the text inside of the <cite> tag in italics, but this can be changed with a touch of CSS.

The <cite> tag is really useful for citing bibliographic and other site references. Here’s an example of how to use the cite tag in a paragraph:

David Allen’s breakthrough organization book Getting Things Done has taken the web by storm.

2. <optgroup>

The <optgroup> tag is a great way to add a little definition between groups of options inside a select box. If you needed to group movie listings by time, for example, then it would look like this:


Live demo:

This allows the select list to visually separate the movie listings.

3. <acronym>

The <acronym> tag is a way to define or further explain a group of words. When you hover over text that has the <acronym> tag used, a box appears below with the text from the title tag. For example:

The microblogging site  Twitter has recently struggled with downtimes.

Live demo:

SEO is full of trickery and magic.

4. <address>

The <address> tag is quite an obscure little tag, but that doesn’t mean it isn’t useful! As the name implies, <address> allows you to semantically markup addresses in HTML. The nifty little tag will also italicize all of the data within the brackets, though the style can easily be changed through simple CSS.

Glen Stansberry 1234 Web Dev Lane Anywhere, USA

5. <ins> and <del>

If you’re wanting to display editing revisions with with markup, <ins> and <del> are just the ticket. Like the name implies, <ins> highlights what’s been added to the document with an underline, and <del> shows what’s been taken out with a strikethrough.

John likes LOVES his new iPod.

Live demo:

John likes LOVES his new iPod.

6. <label>

Form elements seem the easiest to forget when marking up a document. Of the form elements, one of the most forgotten is the <label> tag. Not only is it a quick way to note the label’s text, the <label> tag can also pass a “for” attribute to specify which element is to be given the label. Not only are these <label> tags great for styling, they also allow you to make the caption clickable for the associated element.


7. <fieldset>

Fieldset is a nifty little attribute that you can add to your forms to logically group form elements. Once applied the <fieldset> tag draws a box around the elements within the fieldset. Bonus points for adding a <label> tag within the fieldset to define the title of the group.

Are You Smarter Than a 5th Grader? Yes No

Live demo:

Are You Smarter Than a 5th Grader?

Yes

No

8. <abbr>

The <abbr> tag is much akin to the <acronym> tag, except the <abbr> tag is only used to define abbreviated words. Just like <acronym>, you define a title within the tag. When a visitor hovers over the abbreviated text, the full definition appears below. The <abbr> tag is rarely used, but the benefits are many for screen readers, spellcheckers and search engines.

Sgt. Pepper's Lonely Hearts Club is my favorite album.

Live demo:

Sgt. Pepper’s Lonely Hearts Club is my favorite album.

9. rel

Rel can be an insanely useful attribute, as any HTML element can have a rel applied to it. It’s helpful for passing extra variables that aren’t otherwise specified. This is helpful when using Javascript with your HTML. If you have a link that you want to edit inline, you might add:

This link is editable

The Javascript might be looking for a link with the rel attribute “clickable”, and it knows to apply some Ajax and allow it to be edited inline. This is one of many techniques you can use with the rel attribute, as the possibilities are endless.

10. <wbr>

The <wbr> tag is an incredibly obscure tag. To be honest, I doubt many of you have come into contact with the tag, as it’s hardly ever used. (Truthfully, I hadn’t seen the tag before I started researching this article.) Essentially, the tag allows you to specify a place where you think a line break might be useful, but only if needed. This tag is unique as it relies on the discretion of the browser to insert the linebreak, if needed. It’s perfect for creating layouts that you want to avoid having horizontal scrollbars.

If you were wanting to achieve the same effect but without using the <wbr> tag, you could also try or ­­. It should be noted that none of these tags have full support across all browsers. To see which browsers support the tags check out this article by Quirksmode.

How do you say Supercalifragilisticexpialidocious?

Note: Want to add some source code? Type <pre><code> before it and </code></pre> after it. Find out more
  • http://adambrunner.blogspot.com Adam

    At the fieldset section, you mention label instead of legend. BTW, great post! Thanks for it!

  • http://twitter.com/moveax1 Simon

    the radioboxes don’t work right because you’ve given them different name attributes.

    Fine article, i will use the acronym tag more often now.

  • Pingback: Zehn HTML-Tags die man kennen sollte

  • http://www.myfxstudio.com Raza

    Great Work!!!

  • http://graphicriver.net/?ref=Daan Daan Weijers

    I like the entry, however, like half of these aren’t that rare.

  • http://trentwalton.com Trent Walton

    Good post, you learn something new every day… not too heartbroken that doesn’t validate.

  • http://xavia360.com/blog Zohaib

    and , and other new tags are coming in html 5
    http://www.w3schools.com/tags/html5.asp

  • Bree

    Fun post – WBR was a surprise to me.

  • http://www.backlitcreative.com Brian Bell

    In response to all the complainers… You can never make all the geeks happy. I think the post is great and I appreciate the effort to put this list together.

    • http://www.chris-wallace.com Chris Wallace

      The post is great if you want to learn how to write HTML poorly.

  • http://www.andymatthews.net Andy Matthews

    Make sure to check our my friend’s site containing lists of commonly underused HTML tags:

    http://showmehtml.com/

  • http://URL(Optional) anom

    wbr is invalid markup!

  • http://URL(Optional) anom

    document.write(‘xss’);

  • http://www.yoursash.com Your Sash Staff

    Great list of tags. The cite one is very useful, thanks for sharing!

  • http://bucktowndigital.com bucktowndigital

    stellar list

  • Pingback: 10 Really cool HTML tags… | No Time to Think

  • http://www.lgrassini.com Lisandro Grassini

    The TABLE tag should be in this list instead of LABEL… I use the LABEL tag all the time in order to create forms without tables. Regards!

  • CHose

    Most are useless… just use styled divs damnit!

  • CHose

    Note that there are characters such as zero-width space or soft-hyphens, that do the same job as the tags described here.

  • http://www.jampmark.com Jamp Mark

    they are not really rare and they are used on pages where appropriate. i’ve seen them a lot on bibliographies, thesis, survey forms, etc. i agree with you on . it is hardly ever used.

  • Pingback: links for 2009-03-25 « LAN b4 Time

  • http://gfx-inc.net Gary Callaghan

    Some very nice tags there that i haven’t seen before, Most of the tags you mentioned should be used more reguarly as they are very handy.

    Thanks for this article.

  • http://www.theloveofcode.com The Love of Code

    Nice list. I would say that the rel attribute isn’t really all that rare. It’s starting to show up a lot for various JavaScript/AJAX and SEO tricks.

    Your list is missing a set of tags that are rare in my opinion: DL, DD, and DT. The definition tags are rarely seen, but can be quite useful for term definitions or even FAQ pages.

  • Pingback: Daily Digest for 2009-03-25 | Pedro Trindade

  • Pingback: Submit Links, Add Upload Submit, Funny Game Movie TV Links, Heroes |

  • Pingback: 10 Rare HTML Tags | Design Shack

  • Peter C.

    I can only re-iterate what has already been said in the previous comments. Yet another woefully inaccurate article from Mr Stansberry. Here’s to future Nettuts+ articles being much more on-target and faithful to their titles!

  • http://www.ladadadada.net/ Dave

    More bugs: Your radio buttons are not linked so you can select all of them at once and on FF3 the fieldset does not draw a box around the fields. (At least, it doesn’t in your example.)

    The wbr tag does not have good support across all browsers. More info on Quirksmode: http://www.quirksmode.org/oddsandends/wbr.html

    “rel” seems out of place in a list of html tags but, as you said, it can be very useful and seeing it on anything other than link or anchor tags is quite rare.

    Don’t forget when making AJAXy things that not every uses javascript. Make sure your links and buttons still work with javascript turned off. Especially in the case of links, this will help your Google ranking as well as not turning away visitors who don’t have javascript turned on. (Like me)

    For instance, there are no labels on this comment form. They are placed inline using javascript after the page loads. I can either guess that they are in Name, email, URL format as most blogs use or I can look at the source code and hope that the names are descriptive. For some reason you have used the attribute “defaultvalue” in these input fields which does not exist rather than the more standard “value”… which would have worked. Using a label would have been a much better idea.

    I think it would be a better use of your time to run your pages through the W3C validator than to start learning obscure and badly supported tags that add very little benefit to the average user.

  • Pingback: Awesome Find #6: Ten Useful But Obscure HTML Tags | Daily Cup of Tech

  • Pingback: Thursday News Yummies | Bernskiold Media

  • Pingback: あなたが本当に知るべき10の稀有なHTMLタグ | Designeo

  • http://www.bubbila.com Steve

    Great Post, I never new they existed…

  • Vole

    should be used for acronyms

    acronyms are abbreviations pronounced as words rather than as inidividual letters

    radar

    laser

  • Pingback: Rare HTML Tags « Frontier Label Tech Blog

  • Pingback: Add More Tags to Your Toolbox « MEDIA SALT

  • Trae

    I enjoy the tag. I like to put it on text then specify a brown color with font-weight bold in CSS. Does the trick every time.

  • http://itlivewre.com Gerard Banasig

    I miss the tag =)

  • http://itlivewre.com Gerard Banasig

    I miss the marquee tag =)

  • Pingback: JeremiahTolbert.com » Blog Archive » links for 2009-03-26

  • http://chibidesign.com keruchan

    haha I never use any of them except for the ‘rel’ tag. I guess I’m too young to saw them in action way back decades ago.

  • http://blog.debajit.com Debajit

    I think an important “rare” tag that is missing from this list is the q tag.

  • Pingback: Rare HTML Tags: Help Your Readers | Devlounge

  • tedeh

    What’s most sad isn’t the fact that this Jesus-esque character “Glen Stansberry” made money on writing this “fine” piece of … article, but that more feeble minded developers are taking these “tips” at face-value, quite possibly applying them in their work. Here’s what I have to say: read the first 20 comments and learn the real deal.

    The wbr-tag you say? Why not also enlighten us on the usage of the marquee-tag and the blink-tag too? Haven’t seen those around lately.

  • Pingback: links for 2009-03-26 • Bare Identity

  • Nope

    Jesus…you guys are such nit-picky bastards. Does anyone actually code or do you spend every ounce of your time picking through simple tutorials and arguing with each other over correct semantics…and spelling in each others comments. For christ sakes…i could only read like the first 15 comments before i confirmed that i was wasting my time. And yeah, i prolly spelled something wrong.

  • Pingback: 與 HLB 的對話

  • http://www.pollyjuice.se Maria

    Thank you, I wasn’t aware of all of these, but now that I do, I’ll definitely be using a few of them.

  • Martin

    Paul Armstrong – get over yourself.
    It is most unfortunate that you used the phrase “Most unfortunate”.

    Don’t make the comments your platform for showing how much you know.

    Make your points and move on.

    Debating whether on not NCAA is an abbreviation. Get a life.

    • http://www.chris-wallace.com Chris Wallace

      It’s not an abbreviation. If you try to teach someone how to spell the word “bark” and they spell it “barc” they would need to be corrected. Sure it “sounds” the same, but it’s not the right way to spell it. When what you’re doing is educating others, you need to be precise with what you say and teach.

  • Pingback: The Great Geek Manual » Link Round-Up: March 27, 2009

  • John

    It’s shopped

  • Pingback: 你必须知道的10个不常用的HTML标签 | 前端观察