I have been working with some designs and I had to center an image in few pages. Previously I used to use <center> tag around the image tag and it works like a charm. But the <center> tag is deprecated in HTML5 and there is a beautiful way around to do this using CSS. Add the following code to make the image aligned exactly to the center of any web page.
This piece of code works like a charm.