Skip to main content

A high-level API to automate web browsers

Project description

🎭 Playwright for Python PyPI version Anaconda version Join Discord

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 134.0.6998.35
WebKit 18.4
Firefox 135.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://playwright.dev')
        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://playwright.dev')
            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


Release history Release notifications | RSS feed

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

Uploaded Python 3 Windows x86-64

playwright-1.51.0-py3-none-win32.whl (34.9 MB view details)

Uploaded Python 3 Windows x86

playwright-1.51.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (44.6 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ARM64

playwright-1.51.0-py3-none-manylinux1_x86_64.whl (45.2 MB view details)

Uploaded Python 3

playwright-1.51.0-py3-none-macosx_11_0_universal2.whl (39.6 MB view details)

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

playwright-1.51.0-py3-none-macosx_11_0_arm64.whl (38.0 MB view details)

Uploaded Python 3 macOS 11.0+ ARM64

playwright-1.51.0-py3-none-macosx_10_13_x86_64.whl (39.6 MB view details)

Uploaded Python 3 macOS 10.13+ x86-64

File details

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

File metadata

File hashes

Hashes for playwright-1.51.0-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 9ece9316c5d383aed1a207f079fc2d552fff92184f0ecf37cc596e912d00a8c3
MD5 4d2ebc2a633427adcc2532c9b908f1ed
BLAKE2b-256 200f098488de02e3d52fc77e8d55c1467f6703701b6ea6788f40409bb8c00dd4

See more details on using hashes here.

File details

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

File metadata

  • Download URL: playwright-1.51.0-py3-none-win32.whl
  • Upload date:
  • Size: 34.9 MB
  • Tags: Python 3, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: RestSharp/106.13.0.0

File hashes

Hashes for playwright-1.51.0-py3-none-win32.whl
Algorithm Hash digest
SHA256 4cef804991867ea27f608b70fa288ee52a57651e22d02ab287f98f8620b9408c
MD5 49183dbd000a81457e40725b5e4d2495
BLAKE2b-256 51e44342f0bd51727df790deda95ee35db066ac05cf4593a73d0c42249fa39a6

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for playwright-1.51.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 814e4ec2a1a0d6f6221f075622c06b31ceb2bdc6d622258cfefed900c01569ae
MD5 738f4574a1207c7685359bca80ce1030
BLAKE2b-256 0d1413db550d7b892aefe80f8581c6557a17cbfc2e084383cd09d25fdd488f6e

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for playwright-1.51.0-py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 d5c9f67bc6ef49094618991c78a1466c5bac5ed09157660d78b8510b77f92746
MD5 5bfb83bb0c0a30701449e71fa0c1a9c5
BLAKE2b-256 7afdbc60798803414ecab66456208eeff4308344d0c055ca0d294d2cdd692b60

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for playwright-1.51.0-py3-none-macosx_11_0_universal2.whl
Algorithm Hash digest
SHA256 ab4c0ff00bded52c946be60734868febc964c8a08a9b448d7c20cb3811c6521c
MD5 9f3d1f9912e66ef13426d9f9be242faf
BLAKE2b-256 bab1061c322319072225beba45e8c6695b7c1429f83bb97bdb5ed51ea3a009fc

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for playwright-1.51.0-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 2e0ae6eb44297b24738e1a6d9c580ca4243b4e21b7e65cf936a71492c08dd0d4
MD5 811a23105dc69567b5117dfa0b066b08
BLAKE2b-256 324a5f2ff6866bdf88e86147930b0be86b227f3691f4eb01daad5198302a8cbe

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for playwright-1.51.0-py3-none-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 bcaaa3d5d73bda659bfb9ff2a288b51e85a91bd89eda86eaf8186550973e416a
MD5 f80294fd8c0e285a51166d322d777933
BLAKE2b-256 1be9db98b5a8a41b3691be52dcc9b9d11b5db01bfc9b835e8e3ffe387b5c9266

See more details on using hashes here.

Supported by

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