<! DOCTYPE html>Div{width:100px;height:100px;background:red;position:relative;animation:myfirst 5s;-moz-animation:myfirst 5s;/*Firefox*/-webkit-animation:myfirst 5s;/*Safari and Chrome*/-o-animation:myfirst 5s;/*Opera*/} @keyframes myfirst{0%{background:red; left:0px; top:0px;} -%{background:yellow; left:200px; top:0px;} -%{background:blue; left:200px; top:200px;} the%{background:green; left:0px; top:200px;} -%{background:red; left:0px; top:0px;}} @-moz-keyframes Myfirst/*Firefox*/{0%{background:red; left:0px; top:0px;} -%{background:yellow; left:200px; top:0px;} -%{background:blue; left:200px; top:200px;} the%{background:green; left:0px; top:200px;} -%{background:red; left:0px; top:0px;}} @-webkit-keyframes Myfirst/*Safari and Chrome*/{0%{background:red; left:0px; top:0px;} -%{background:yellow; left:200px; top:0px;} -%{background:blue; left:200px; top:200px;} the%{background:green; left:0px; top:200px;} -%{background:red; left:0px; top:0px;}} @-o-keyframes Myfirst/*Opera*/{0%{background:red; left:0px; top:0px;} -%{background:yellow; left:200px; top:0px;} -%{background:blue; left:200px; top:200px;} the%{background:green; left:0px; top:200px;} -%{background:red; left:0px; top:0px;}}</style>The square of jquery moves