Skip to main content

Read the latest Real Python tutorials

Project description


Instant visualization of Python AST and Code Objects.


Requires modern Python 3.6+

pip install instaviz


Instaviz is designed to be used like PDB, it will start a webserver when the show() function is called. Simply pass a class or function to be displayed

def my_function():
    # your code

# your code
import instaviz;

You can also run instaviz inside the Python REPL.

[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import instaviz
>>> def fib(n):
...     a, b = 1, 1
...     for i in range(2, n + 1):
...         a, b = b, a + b
...     return b
Bottle v0.12.17 server starting up (using WSGIRefServer())...
Listening on http://localhost:8080/
Hit Ctrl-C to quit.


This package bundles some 3rd party javascript libraries. All libraries are bundled in the package so that the WebUI doesn't need to make any requests to the internet to protect the privacy of your code.

json2html json2html-visualizer visjs

Project details

Download files

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

Files for instaviz, version 0.6.0
Filename, size File type Python version Upload date Hashes
Filename, size instaviz-0.6.0-py3-none-any.whl (462.4 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size instaviz-0.6.0.tar.gz (454.7 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page