I have seen many bloggers who is having their own YouTube channel as well as website. when writing the blog on the website they want to promote their YouTube channel as a part of promotion. this can be achieved very easily with the help of YouTube developer tool. you need to follow the following step to create YouTube subscriber button.
1) Click on the following link to configure YouTube subscriber pattern. (Youtube Developer Link)
2) Enter the channel name or ID channel name can get from following link. (Youtube Setting)
3) Please login to your youtube channel
4) Insert layout, theme, subscriber count as per your requirement.
5) You will find the code has been generated automatically on your options selected above.
6) Copy the code and paste it into website html code.
7) Follow the following Video to know more about with practically presented very well.