← Back to library
Playwrightfixturesadvancedv1.20+

Run tests across multiple browsers

Configure projects in playwright.config.ts so every test runs on Chromium, Firefox, and WebKit.

1// playwright.config.ts
2import { defineConfig, devices } from '@playwright/test';
3
4export default defineConfig({
5  projects: [
6    { name: 'chromium', use: { ...devices['Desktop Chrome']  } },
7    { name: 'firefox',  use: { ...devices['Desktop Firefox'] } },
8    { name: 'webkit',   use: { ...devices['Desktop Safari']  } },
9  ],
10});
11
12// Run all browsers:     npx playwright test
13// Run one browser only: npx playwright test --project=firefox
#projects#cross-browser#firefox#webkit#config