How do I create a PDF from HTML 1

How do I create a PDF from HTML
wkhtmltopdf is command line tools to render HTML into PDF. Real world example : 1 ) Like QA need to capture information in pdf or create sanity report than its very helpful to create pdf files. 2 ) E-commerce invoice created in html but you want to provide pdf invoice on there mail at that ...