Yes knowledge of html is very necessary in On Page Optimization.