<html> <body> <div style="height: 10000px;"></div> <div style="position: relative;"> <div id="test2" style="position:absolute; top:-200px;"></div> <div style="height: 100px; width: 100px; background: blue;"></div> </div> <div style="height: 10000px;"></div> </body> </html>