How to enable ssl in tomcat?

First Generate SSl cirtificate.
If you don’t know about generating SSL certificate, please read post How to generate ssl certificate?
Then open tomcat/conf/server.xml
Go to ssl connector tag.
Add the following properties to the connector tag.
keystoreFile=”{{certificate location in ur machine}}”
keystorePass=”{{password of the certificate}}”
Test tomcat.
Eg https://localhost:8080/