# How to create link shortner using python in less than 5 lines of code

**URL:** <https://onehack.st/t/how-to-create-link-shortner-using-python-in-less-than-5-lines-of-code/82061>\
**Category:** Tutorials & Methods\
**Tags:** tools, tips-tricks\
**Created:** [April 25, 2020, 3:26am UTC](https://onehack.st/t/how-to-create-link-shortner-using-python-in-less-than-5-lines-of-code/82061 "2020-04-25T03:26:45Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![RoohNooh](https://onehack.st/user_avatar/onehack.st/roohnooh/32/166257_2.png) [@RoohNooh](https://onehack.st/u/RoohNooh)\
**Post date:** [April 25, 2020, 3:26am UTC](https://onehack.st/t/how-to-create-link-shortner-using-python-in-less-than-5-lines-of-code/82061/1 "2020-04-25T03:26:54Z")

</div>

[![](https://img.youtube.com/vi/6DhSLGPsyq4/maxresdefault.jpg "How to create link shortner using python in less than 5 lines of code") ](https://www.youtube.com/watch?v=6DhSLGPsyq4)

In this video you will learn how you can create a link shortener using python with the help of pyshorteners package. pyshorteners is a Python lib to help you short and expand urls using the most famous URL Shorteners available

pypi link to pyshorteners: [https://pypi.org/project/pyshorteners/](https://pypi.org/project/pyshorteners/)

---

<div class="post-metadata">

**Author:** ![Astrocode](https://onehack.st/user_avatar/onehack.st/astrocode/32/37705_2.png) [@Astrocode](https://onehack.st/u/Astrocode)\
**Post date:** [April 27, 2020, 11:45am UTC](https://onehack.st/t/how-to-create-link-shortner-using-python-in-less-than-5-lines-of-code/82061/2 "2020-04-27T11:45:53Z")

</div>

Thanks for sharing!
