Your config, ready to paste
Drop this into playwright.config.ts at your project root.
import { defineConfig, devices } from "@playwright/test";
// Generated by TestDino Playwright Config Generator
// https://testdino.com/tools/playwright-config-generator
export default defineConfig({
testDir: "./tests",
timeout: 30000,
expect: { timeout: 5000 },
fullyParallel: true,
workers: process.env.CI ? 4 : undefined,
retries: process.env.CI ? 2 : 0,
forbidOnly: !!process.env.CI,
reporter: [
["html"],
["list"],
process.env.CI ? ["github"] : null
].filter(Boolean),
use: {
baseURL: "https://example.com",
trace: "on-first-retry",
screenshot: "only-on-failure",
video: "retain-on-failure",
},
projects: [
{ name: "chromium", use: { ...devices["Desktop Chrome"] } },
{ name: "firefox", use: { ...devices["Desktop Firefox"] } }
],
});Install the packages
Run these once in your project. Skip any package you already have.
npm install --save-dev @playwright/test
npx playwright installHow this works?
How the generator builds a production-ready playwright.config.ts from your selections.
Pick your browsers and workers
Choose which browsers Playwright runs against and how many parallel workers to use in CI. Each combination generates the matching projects block.
Set retries, timeouts, and artifacts
Configure retries for CI and local runs, test and expect timeouts, and when to capture traces, screenshots, and video. Defaults follow Playwright's recommended settings.
Choose your reporters
Select HTML, list, JSON, GitHub annotations, or the TestDino reporter. The generator adds each reporter to the array and filters out the GitHub one on local runs automatically.
Copy your config and install command
The generated playwright.config.ts updates as you change any option. Copy it into your project root, then run the install command to get the required packages.
More free tools for Playwright teams
FAQs
Yes. Toggle the TypeScript option to switch between an ES module config using import/export default and a CommonJS config using require/module.exports. The file name updates to playwright.config.ts or playwright.config.js accordingly.
