# Using fonts in cv2.putText method?

**URL:** <https://forum.opencv.org/t/using-fonts-in-cv2-puttext-method/872>\
**Category:** Python\
**Created:** [January 15, 2021, 8:15am UTC](https://forum.opencv.org/t/using-fonts-in-cv2-puttext-method/872 "2021-01-15T08:15:42Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![diasbalmash](https://avatars.discourse-cdn.com/v4/letter/d/e8c25b/32.png) [@diasbalmash](https://forum.opencv.org/u/diasbalmash)\
**Post date:** [January 15, 2021, 8:15am UTC](https://forum.opencv.org/t/using-fonts-in-cv2-puttext-method/872/1 "2021-01-15T08:15:42Z")

</div>

How to use fonts other than Hershey in the cv2.Puttext method?

---

<div class="post-metadata">

**Author:** ![Ceopee](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.opencv.org/ceopee/32/531_2.png) [@Ceopee](https://forum.opencv.org/u/Ceopee)\
**Post date:** [January 15, 2021, 8:52am UTC](https://forum.opencv.org/t/using-fonts-in-cv2-puttext-method/872/2 "2021-01-15T08:52:50Z")

</div>

If you are gonna use custom fonts, OpenCV supports [FreeType2](https://docs.opencv.org/master/d9/dfa/classcv_1_1freetype_1_1FreeType2.html) class. There is also a sample code there. Related so question and my ref is from [this post](https://stackoverflow.com/questions/37191008/load-truetype-font-to-opencv)

TTF is okay as an extension and some others might be imported as well not sure.
