Code Snippet

Home » Code Snippets » CSS » Removing Dotted Outline

Removing Dotted Outline

a {
   outline: 0;
}

Be careful removing outline styles from links, as they are a usability feature. If you do, make sure to define clear focus styles.

If your problem is that the dotted outlines travel all the way to the left or right of the screen because they are floated, try setting the overflow to hidden.

Subscribe to The Thread

  1. elandy2009

    A note: The “outline” CSS property doesn’t work in IE6 and IE7.

  2. This works.

    a {
    outline-style: none;
    }

  3. *:focus { outline: 0; }

  4. Court Kizer

    Outline: 0 none; <– Use this for perfect outline kill, every…single…time

Speak, my friend

At this moment, you have an awesome opportunity* to be the person your mother always wanted you to be: kind, helpful, and smart. Do that, and we'll give you a big ol' gold star for the day (literally).

Posting tips:
  • You can use basic HTML
  • When posting code, please turn all
    < characters into &lt;
  • If the code is multi-line, use
    <pre><code></code></pre>
Thank you,
~ The Management ~