Skip to content

Instantly share code, notes, and snippets.

@sandgate-dev
Created March 11, 2019 08:33
Show Gist options
  • Save sandgate-dev/467214cfbd8bcbadaa93361d61208df0 to your computer and use it in GitHub Desktop.
Save sandgate-dev/467214cfbd8bcbadaa93361d61208df0 to your computer and use it in GitHub Desktop.
import tldextract
list = tldextract.extract('http://blog.ashiknesin.com/about')
domain_name = list.domain + '.' + list.suffix
# ashiknesin.com
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment