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 100.0.4863.0
WebKit 15.4
Firefox 96.0.1

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.19.0-py3-none-win_amd64.whl (27.5 MB view details)

Uploaded Python 3 Windows x86-64

playwright-1.19.0-py3-none-win32.whl (27.5 MB view details)

Uploaded Python 3 Windows x86

playwright-1.19.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (33.2 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ARM64

playwright-1.19.0-py3-none-manylinux1_x86_64.whl (33.3 MB view details)

Uploaded Python 3

playwright-1.19.0-py3-none-macosx_11_0_universal2.whl (31.0 MB view details)

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

playwright-1.19.0-py3-none-macosx_11_0_arm64.whl (29.5 MB view details)

Uploaded Python 3 macOS 11.0+ ARM64

playwright-1.19.0-py3-none-macosx_10_13_x86_64.whl (31.0 MB view details)

Uploaded Python 3 macOS 10.13+ x86-64

File details

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

File metadata

  • Download URL: playwright-1.19.0-py3-none-win_amd64.whl
  • Upload date:
  • Size: 27.5 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for playwright-1.19.0-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 5febf7069572f34271f2d594a67fd2cdcffa7b83e4295db97c4b3825b3796536
MD5 c21b55468a190711b525b5f6b372ed84
BLAKE2b-256 85ad78eaeaa56bc70ea7d7b73135b40c49d9b12832c8e8d3c9795f0c8f0229a5

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.19.0-py3-none-win32.whl
  • Upload date:
  • Size: 27.5 MB
  • Tags: Python 3, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for playwright-1.19.0-py3-none-win32.whl
Algorithm Hash digest
SHA256 7a8cd4ad53d70fcc46fc8947d243bfc1c7356256a1b3303cbd209a35736d2f9b
MD5 a158d5c062f0a0648b5cb550f547a841
BLAKE2b-256 2da3275a102e01725bb08ae25362db8a57ad9adf4dd500468dd2a080a28be41b

See more details on using hashes here.

File details

Details for the file playwright-1.19.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

  • Download URL: playwright-1.19.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
  • Upload date:
  • Size: 33.2 MB
  • Tags: Python 3, manylinux: glibc 2.17+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for playwright-1.19.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 99b074c91869dbe303fca8b122913d747c0b2a8c744ead60d7991cee3ce98c20
MD5 05c16b294106daada60963c4827ee193
BLAKE2b-256 bf5f0e9ccd88613fa62923f3858223ee4ceee37c4da102dc1cde4cf17b2dddc9

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.19.0-py3-none-manylinux1_x86_64.whl
  • Upload date:
  • Size: 33.3 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for playwright-1.19.0-py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 2373ddc133dea6889686562b2489de90a50b7ed0194f948aa06a3704e60a0c4b
MD5 b4b0aad8c3ff88aded0ce5f6842a0501
BLAKE2b-256 9c723fb51087950f392c2b7e66532cfa23c94c6d5c97fb25de0c06e6a8012b2e

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.19.0-py3-none-macosx_11_0_universal2.whl
  • Upload date:
  • Size: 31.0 MB
  • Tags: Python 3, macOS 11.0+ universal2 (ARM64, x86-64)
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for playwright-1.19.0-py3-none-macosx_11_0_universal2.whl
Algorithm Hash digest
SHA256 0c7b29bef3722b3b118178082820a230ed0817ab88061c32867dcfb582a00ac3
MD5 52b1c949be633c6e653fb08774f6054c
BLAKE2b-256 979c3f39f0c71a86adfbea88a66f974dbd6cb2aecfbbf21dd632e8e59b8b6a04

See more details on using hashes here.

File details

Details for the file playwright-1.19.0-py3-none-macosx_11_0_arm64.whl.

File metadata

  • Download URL: playwright-1.19.0-py3-none-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 29.5 MB
  • Tags: Python 3, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for playwright-1.19.0-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 5253b1235e4498fb61765223cf81e92600e00d3ad436a4dc028666c218438cfa
MD5 cd586e79b0e0c7e65cfea0c3d606804d
BLAKE2b-256 504b8a7a89b57326a09df3796a13f5191757630f2a18f2b1802c9ee68f33afff

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.19.0-py3-none-macosx_10_13_x86_64.whl
  • Upload date:
  • Size: 31.0 MB
  • Tags: Python 3, macOS 10.13+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for playwright-1.19.0-py3-none-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 2a5b38514339f0e7456598ae7713c095d6acafa05fc2396b93cf8428e87373d5
MD5 91e1297c1a745c5132137b995fd32ac2
BLAKE2b-256 dbf8228c2848afd343d3da6707f2b251d9ec414f6bac242c067746c047a7328c

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