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 98.0.4695.0
WebKit 15.4
Firefox 94.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.17.2-py3-none-win_amd64.whl (27.5 MB view details)

Uploaded Python 3 Windows x86-64

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

Uploaded Python 3 Windows x86

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

Uploaded Python 3 manylinux: glibc 2.17+ ARM64

playwright-1.17.2-py3-none-macosx_11_0_universal2.whl (30.9 MB view details)

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

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

Uploaded Python 3 macOS 11.0+ ARM64

playwright-1.17.2-py3-none-macosx_10_13_x86_64.whl (30.9 MB view details)

Uploaded Python 3 macOS 10.13+ x86-64

File details

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

File metadata

  • Download URL: playwright-1.17.2-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.4.2 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for playwright-1.17.2-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 f64403941e0d6bfcc92d451150bbdb4d8eefdaa0c26866c27304106f86923d60
MD5 7d81477cece8620cdfc11d1a585c8741
BLAKE2b-256 4260917ecb1a27bed6f13925df7c032efea2bba5e1e6b848812273dc2d361636

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for playwright-1.17.2-py3-none-win32.whl
Algorithm Hash digest
SHA256 8fefe383ba1baf474534c6fc2338113318725c420639bdbe1a57a371c20245b3
MD5 d4995f35588e55733c3eee37bbbc063d
BLAKE2b-256 4346380ca28278821ed5a9e2e66ec2a0e6a33408fb35f42e19ba07bcfd87f130

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for playwright-1.17.2-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 b2ad61a2ba78149a2f32d18926c045e68782d5dc0e7250e7ce43643da142cc64
MD5 bba811866f0758fc2a305b9fb38d1ecb
BLAKE2b-256 d22213749a5d06618fbe45f6149edab9c4bf6fc707961a4bc0230decd92ef2ef

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.17.2-py3-none-manylinux1_x86_64.whl
  • Upload date:
  • Size: 33.3 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for playwright-1.17.2-py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 0164ba36a0eab00217ae548961bba92e2c67186f6b6ac43c2240c86663de6fa1
MD5 40933579e93ea06d85e23f494302e8d8
BLAKE2b-256 a5f9fd9db6c88dc8ccba51b2f22d9c16fe64bd9406cbf4c2e8115b5090a74d6c

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.17.2-py3-none-macosx_11_0_universal2.whl
  • Upload date:
  • Size: 30.9 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.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for playwright-1.17.2-py3-none-macosx_11_0_universal2.whl
Algorithm Hash digest
SHA256 404135562a8f49f29174073a4d6af6dc12021db256c01b4a983cce9438c203c6
MD5 7be36a4fb3f35e6093ba66eeb2910706
BLAKE2b-256 bbc6db37cd7456db1e95381b6f448b97dbde0e7a1f68a0b99bcd0b6d9fe8cb1b

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.17.2-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.4.2 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for playwright-1.17.2-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c78cc49ad970ddcec442aef70517aedc2196c5ef416c67f3e8fbbd1bd0ddfb64
MD5 5eeaaa01504f32a443dfe8efbbab1f3b
BLAKE2b-256 3d4bb0e6678594f44a942cc122457cd0285acf737ad07f47a73aae8f1a139775

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for playwright-1.17.2-py3-none-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 9dcdb31f73fccbf8f23f90ac0c18cefaabe05ef78fe9861771b460aa312f4bc9
MD5 fe0ab24aee76c068b230d70d0059aaef
BLAKE2b-256 14286ef42e67f075638f3436fde2f07ef1ff2a870d7e55e1dbecf73d549ee947

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