Skip to main content

Universal encoding detector for Python 2 and 3

Project description

Chardet: The Universal Character Encoding Detector

Detects
  • ASCII, UTF-8, UTF-16 (2 variants), UTF-32 (4 variants)

  • Big5, GB2312, EUC-TW, HZ-GB-2312, ISO-2022-CN (Traditional and Simplified Chinese)

  • EUC-JP, SHIFT_JIS, CP932, ISO-2022-JP (Japanese)

  • EUC-KR, ISO-2022-KR (Korean)

  • KOI8-R, MacCyrillic, IBM855, IBM866, ISO-8859-5, windows-1251 (Cyrillic)

  • ISO-8859-2, windows-1250 (Hungarian)

  • ISO-8859-5, windows-1251 (Bulgarian)

  • windows-1252 (English)

  • ISO-8859-7, windows-1253 (Greek)

  • ISO-8859-8, windows-1255 (Visual and Logical Hebrew)

  • TIS-620 (Thai)

Requires Python 2.6 or later

Installation

Install from PyPI:

pip install chardet

Command-line Tool

chardet comes with a command-line script which reports on the encodings of one or more files:

% chardetect somefile someotherfile
somefile: windows-1252 with confidence 0.5
someotherfile: ascii with confidence 1.0

About

This is a continuation of Mark Pilgrim’s excellent chardet. Previously, two versions needed to be maintained: one that supported python 2.x and one that supported python 3.x. We’ve recently merged with Ian Cordasco’s charade fork, so now we have one coherent version that works for Python 2.6+.

maintainer:

Dan Blanchard

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

chardet-2.3.0.tar.gz (164.3 kB view details)

Uploaded Source

Built Distribution

chardet-2.3.0-py2.py3-none-any.whl (180.9 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file chardet-2.3.0.tar.gz.

File metadata

  • Download URL: chardet-2.3.0.tar.gz
  • Upload date:
  • Size: 164.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for chardet-2.3.0.tar.gz
Algorithm Hash digest
SHA256 e53e38b3a4afe6d1132de62b7400a4ac363452dc5dfcf8d88e8e0cce663c68aa
MD5 25274d664ccb5130adae08047416e1a8
BLAKE2b-256 7d874e3a3f38b2f5c578ce44f8dc2aa053217de9f0b6d737739b0ddac38ed237

See more details on using hashes here.

File details

Details for the file chardet-2.3.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for chardet-2.3.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 aaf514bde38020b4f1e42c6a6e141f2827a8a58ccfc3b22b6ff5a1a4b50be56e
MD5 ed72df7ce6a2956ac3483e029d951fa2
BLAKE2b-256 7e5c605ca2daa5cf21c87690d8fe6ab05a6f2278c451f4ede6456dd26453f4bd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page