Code Snippet

Home » Code Snippets » CSS » Bouncy Animated Loading Animation

Bouncy Animated Loading Animation

Just some funzies with CSS3 animations. If you are worried about super deep browser support, use a GIF.

<div class="loader">
    <span></span>
    <span></span>
    <span></span>
</div>
.loader {
    text-align: center;
}
.loader span {
    display: inline-block;
    vertical-align: middle;
    width: 10px;
    height: 10px;
    margin: 50px auto;
    background: black;
    border-radius: 50px;
    -webkit-animation: loader 0.9s infinite alternate;
    -moz-animation: loader 0.9s infinite alternate;
}
.loader span:nth-of-type(2) {
    -webkit-animation-delay: 0.3s;
    -moz-animation-delay: 0.3s;
}
.loader span:nth-of-type(3) {
    -webkit-animation-delay: 0.6s;
    -moz-animation-delay: 0.6s;
}
@-webkit-keyframes loader {
  0% {
    width: 10px;
    height: 10px;
    opacity: 0.9;
    -webkit-transform: translateY(0);
  }
  100% {
    width: 24px;
    height: 24px;
    opacity: 0.1;
    -webkit-transform: translateY(-21px);
  }
}
@-moz-keyframes loader {
  0% {
    width: 10px;
    height: 10px;
    opacity: 0.9;
    -moz-transform: translateY(0);
  }
  100% {
    width: 24px;
    height: 24px;
    opacity: 0.1;
    -moz-transform: translateY(-21px);
  }
}

Reference URL

Subscribe to The Thread

  1. Clean & Simple! Nice one Chris!

  2. Wow.. that’s the coolest thing I have seen today.

  3. Rett

    I dont get it!
    What exactly am i looking at here?
    As far as i can tell, its 3 black boxes that do nothing :(

  4. Mike

    Pretty neat. Now I just have to find a way to change it up and implement it.

  5. wicked lookin :)

  6. how could i make this multicolored? i tried and coiuldnt seem to able to seperate the squares with id’s or classes :(

  7. Nice one. There is a whole generator of those things on http://cssload.net. Also, it would be nice if there were a preview of the provided animation

  8. Mike

    Not working in IE9.

    Anyway best thing i´ve seen today.
    I would use it, if it would be compatible at least with IE9.

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 ~