# # Installation

    pip install pywebview

This will install pywebview with default dependencies. To install pywebview with PySide2 (available on Linux and macOS and Windows) use

    pip install pywebview[qt]

To install pywebview with CEF (available on Windows) use

    pip install pywebview[cef]

## # Dependencies

### # Windows

pythonnet
(opens new window) (requires > .NET 4.0)

To use with the latest Chromium you need WebView2 Runtime
(opens new window). If you plan to distribute your software, check out distribution guidelines
(opens new window) too.

To use with CEF you need cefpython
(opens new window)

    pip install cefpython3

### # macOS

pyobjc
(opens new window)

`PyObjC` comes presintalled with the Python bundled in macOS. For a stand-alone Python installation you have to install it separately. You can also use QT5 in macOS

### # Linux

`pip install pywebview[qt]` should take of QT dependencies. If it does not work or you would like to use GTK, you may try these recipes.

PyGObject
(opens new window) is used with GTK. To install dependencies on Ubuntu for both Python 3 and 2

    sudo apt install python3-gi python3-gi-cairo gir1.2-gtk-3.0 gir1.2-webkit2-4.0

For other distributions, consult the PyGObject documentation
(opens new window)

Note that WebKit2 version 2.22 or greater is required for certain features to work correctly. If your distribution ships with an older version, you may need to install it manually from a backport.

PySide2
(opens new window) is used with QT. `pywebview` supports both QtWebChannel (newer and preferred) and QtWebKit implementations. Use QtWebChannel, unless it is not available on your system.

To install QT via pip

    pip install qtpy pyside2

To install QtWebChannel on Debian-based systems (more modern, preferred)

    sudo apt install python3-pyqt5 python3-pyqt5.qtwebengine python3-pyqt5.qtwebchannel libqt5webkit5-dev

To install QtWebKit (legacy, but available for more platforms).

    sudo apt install python3-pyqt5 python3-pyqt5.qtwebkit python-pyqt5 python-pyqt5.qtwebkit libqt5webkit5-dev

WARNING

Starting from Ubuntu Disco Dingo pywebview can be installed via `apt` on Debian based system as `python-pywebview`. This package features an old version of pywebview that is API incompatible with the current version. If you choose to install it, you can find documentation here