Skip to main content

Goal

  • Create a simple importable Python module which will produce parsed WHOIS data for a given domain.

  • Able to extract data for all the popular TLDs (com, org, net, …)

  • Query a WHOIS server directly instead of going through an intermediate web service like many others do.

  • Works with Python 2.4+ and no external dependencies

Example

>>> import whois
>>> w = whois.whois('webscraping.com')
>>> w.expiration_date  # dates converted to datetime object
datetime.datetime(2013, 6, 26, 0, 0)
>>> w.text  # the content downloaded from whois server
u'\nWhois Server Version 2.0\n\nDomain names in the .com and .net
...'

>>> print w  # print values of all found attributes
creation_date: 2004-06-26 00:00:00
domain_name: [u'WEBSCRAPING.COM', u'WEBSCRAPING.COM']
emails: [u'WEBSCRAPING.COM@domainsbyproxy.com', u'WEBSCRAPING.COM@domainsbyproxy.com']
expiration_date: 2013-06-26 00:00:00
...

Install

Install from pypi:

pip install python-whois

Or checkout latest version from repository:

hg clone https://bitbucket.org/richardpenman/pywhois

Contact

You can post ideas or patches here: https://bitbucket.org/richardpenman/pywhois/issues

Thanks to the many who have sent patches for additional domains!

Metadata

Release files for python-whois 0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for python-whois 0.4
File Size Uploaded Provenance
python-whois-0.4.tar.gz 16.6 kB Without provenance Details

Release files / python-whois-0.4.tar.gz

Download URL python-whois-0.4.tar.gz
Size 16.6 kB
Tags Source
SHA-256 checksum
How to use checksums
ed50d36687ee36b6d383d42afe319dfd7aae9da89339a73490e97cd2f2f3762e
BLAKE2b-256 checksum
How to use checksums
094ed01d26496235148607777cdc07687b07b7fb8d3b6f1bfe3d7678bf168ecf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for python-whois 0.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page