Skip to main content

terminaltables

What is it

Easily draw tables in terminal/console applications from a list of lists of strings. Supports multi-line rows.

  • Python 2.6, 2.7, PyPy, PyPy3, 3.3, 3.4, and 3.5+ supported on Linux and OS X.
  • Python 2.7, 3.3, 3.4, and 3.5+ supported on Windows (both 32 and 64 bit versions of Python).

📖 Full documentation: https://robpol86.github.io/terminaltables

Quickstart

Install:

pip install terminaltables

Usage:

from terminaltables import AsciiTable

table_data = [
    ['Heading1', 'Heading2'],
    ['row1 column1', 'row1 column2'],
    ['row2 column1', 'row2 column2'],
    ['row3 column1', 'row3 column2']
]
table = AsciiTable(table_data)
print
table.table
+--------------+--------------+
| Heading1     | Heading2     |
+--------------+--------------+
| row1 column1 | row1 column2 |
| row2 column1 | row2 column2 |
| row3 column1 | row3 column2 |
+--------------+--------------+

Example Implementations

Example Scripts Screenshot

Source code for examples:

Change Log

Release files for terminaltables 3.1.9

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

Source distribution (sdist)

Source distribution for terminaltables 3.1.9
File Size Uploaded
terminaltables-3.1.9.tar.gz 12.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for terminaltables 3.1.9
File Interpreter ABI Platform
terminaltables-3.1.9-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 27.4 kB

Release files / terminaltables-3.1.9.tar.gz

Download URL terminaltables-3.1.9.tar.gz
Size 12.3 kB
Tags Source
SHA-256 checksum
How to use checksums
df28eedd73431283c59c44ebdfaefa6c4905e3d1704a4c2eaf692046efcb6774
BLAKE2b-256 checksum
How to use checksums
c9f83437904b3e5b4f050f1dc254c0eee706df6ff25098cf5b759a33da94a506
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.6.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.8.7

Release files / terminaltables-3.1.9-py2.py3-none-any.whl

Download URL terminaltables-3.1.9-py2.py3-none-any.whl
Size 15.1 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
b4b149ad5c0de74269573dc55f205b6196efe905565fac009724e506d42ea365
BLAKE2b-256 checksum
How to use checksums
d349799fcba07ca12a3b6cb141ac744755306a7d7b6e7d580f08388d2b64a00b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.6.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.8.7

Release history Release notifications | RSS feed

This release

3.1.9 This release

2 release files

3.1.8

2 release files

3.1.7

2 release files

3.1.6

2 release files

3.1.5

1 release file

3.1.0

1 release file

3.0.0

1 release file

2.1.0

1 release file

2.0.0

1 release file

1.2.1

1 release file

1.2.0

1 release file

1.1.1

1 release file

1.1.0

1 release file

1.0.2

1 release file

1.0.1

1 release file

1.0.0

1 release file

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