Skip to main content

A high-level API to automate web browsers

Project description

🎭 Playwright for Python PyPI version Anaconda version Join Slack

Playwright is a Python library to automate Chromium, Firefox and WebKit browsers with a single API. Playwright delivers automation that is ever-green, capable, reliable and fast. See how Playwright is better.

Linux macOS Windows
Chromium 96.0.4641.0
WebKit 15.0
Firefox 92.0

Documentation

https://playwright.dev/python/docs/intro

API Reference

https://playwright.dev/python/docs/api/class-playwright

Example

from playwright.sync_api import sync_playwright

with sync_playwright() as p:
    for browser_type in [p.chromium, p.firefox, p.webkit]:
        browser = browser_type.launch()
        page = browser.new_page()
        page.goto('http://whatsmyuseragent.org/')
        page.screenshot(path=f'example-{browser_type.name}.png')
        browser.close()
import asyncio
from playwright.async_api import async_playwright

async def main():
    async with async_playwright() as p:
        for browser_type in [p.chromium, p.firefox, p.webkit]:
            browser = await browser_type.launch()
            page = await browser.new_page()
            await page.goto('http://whatsmyuseragent.org/')
            await page.screenshot(path=f'example-{browser_type.name}.png')
            await browser.close()

asyncio.run(main())

Other languages

More comfortable in another programming language? Playwright is also available in

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

playwright-1.15.1-py3-none-win_amd64.whl (15.0 MB view details)

Uploaded Python 3 Windows x86-64

playwright-1.15.1-py3-none-win32.whl (13.4 MB view details)

Uploaded Python 3 Windows x86

playwright-1.15.1-py3-none-manylinux1_x86_64.whl (20.2 MB view details)

Uploaded Python 3

playwright-1.15.1-py3-none-macosx_11_0_universal2.whl (18.0 MB view details)

Uploaded Python 3 macOS 11.0+ universal2 (ARM64, x86-64)

playwright-1.15.1-py3-none-macosx_10_13_x86_64.whl (18.0 MB view details)

Uploaded Python 3 macOS 10.13+ x86-64

File details

Details for the file playwright-1.15.1-py3-none-win_amd64.whl.

File metadata

  • Download URL: playwright-1.15.1-py3-none-win_amd64.whl
  • Upload date:
  • Size: 15.0 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for playwright-1.15.1-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 945c82f38488c9c8abbf832a2d5733f49d9a7a87b4b2c27713ffa309ecf54212
MD5 e75f4fc1870aab3b524d64cbe75ba590
BLAKE2b-256 3a4e8831fead7dd667b5ee161c27536446ffcecadafaeda3d0b68ed07588c3f7

See more details on using hashes here.

File details

Details for the file playwright-1.15.1-py3-none-win32.whl.

File metadata

  • Download URL: playwright-1.15.1-py3-none-win32.whl
  • Upload date:
  • Size: 13.4 MB
  • Tags: Python 3, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for playwright-1.15.1-py3-none-win32.whl
Algorithm Hash digest
SHA256 a1a5c931f5dbdb2858ca8f77d9362a3822b97b57f1f0bca864b8b3949163c41a
MD5 8d3e9b9d0b76e317b98ad0299c3c53e6
BLAKE2b-256 df8bef880b68d19f937759fdb266a62493c99a911b57ce5d25fffd6d9577f69b

See more details on using hashes here.

File details

Details for the file playwright-1.15.1-py3-none-manylinux1_x86_64.whl.

File metadata

  • Download URL: playwright-1.15.1-py3-none-manylinux1_x86_64.whl
  • Upload date:
  • Size: 20.2 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for playwright-1.15.1-py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 d4e37016ec5b986afeba1ca8830046f51ac5a6dc82c5811ec788a79fc34c5e09
MD5 c2488db6d138770c51e7d4968e1c5d6f
BLAKE2b-256 f4f062a31a52cc8f56d14f01f9277eb630d7188885d8e0dc9975250e0e020add

See more details on using hashes here.

File details

Details for the file playwright-1.15.1-py3-none-macosx_11_0_universal2.whl.

File metadata

  • Download URL: playwright-1.15.1-py3-none-macosx_11_0_universal2.whl
  • Upload date:
  • Size: 18.0 MB
  • Tags: Python 3, macOS 11.0+ universal2 (ARM64, x86-64)
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for playwright-1.15.1-py3-none-macosx_11_0_universal2.whl
Algorithm Hash digest
SHA256 63d16d5472ea6cf126b3cb9ab05c6075ac9fbef2010da01d3f9a6e3f6e590dab
MD5 21885a633974066c352a7440a8543b5c
BLAKE2b-256 6a20f341db1002b6f452d3ac558f4bb0d6f82aa3d0688d93c4a194e4de343d25

See more details on using hashes here.

File details

Details for the file playwright-1.15.1-py3-none-macosx_10_13_x86_64.whl.

File metadata

  • Download URL: playwright-1.15.1-py3-none-macosx_10_13_x86_64.whl
  • Upload date:
  • Size: 18.0 MB
  • Tags: Python 3, macOS 10.13+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for playwright-1.15.1-py3-none-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 87354f1687808eaaa93bd6405d480d5f35e772f30958f436c3dc49433dbb2d4b
MD5 9444bf4caeeaf557deba5ca767111f49
BLAKE2b-256 2363657d7e41438ff55799179927248aa9f50f141c40aabf4ec4b689ed11c5ca

See more details on using hashes here.

Supported by

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