ReferenceRunners

WebKit support

Run Playwright WebKit tests on Endform's Linux runners to check Safari-like behavior, with how to configure the project, what works well and known limitations.

Endform runs Playwright's Linux WebKit build on isolated ARM64 Linux runners, letting you verify Safari-like rendering and behavior alongside Chromium and Firefox.

Configuring a WebKit project

Configure a Playwright project using devices["Desktop Safari"] (or browserName: "webkit") with a higher per-test timeout to account for Linux WebKit execution speed:

playwright.config.ts
import { defineConfig, devices } from "@playwright/test";

export default defineConfig({
  projects: [
    {
      name: "webkit",
      timeout: 120_000,
      retries: 1,
      testMatch: ["**/checkout.spec.ts", "**/auth.spec.ts"],
      use: {
        ...devices["Desktop Safari"],
      },
    },
  ],
});

Endform detects WebKit from your Playwright project configuration and runs it inside Xvfb with software rendering. Avoid setting channel on a WebKit project (a project-level channel takes precedence over devices["Desktop Safari"] during browser detection); local launchOptions.executablePath overrides are ignored on the runner.

What works well and what to watch for

Works well

  • Page navigation, form interactions, and standard user flows (sign-in, checkout, CRUD)
  • DOM manipulation and JavaScript execution
  • CSS and layout validation (accounting for Linux font differences)
  • Cross-browser checks on critical user journeys

Caveats

  • Tight timeouts and performance-sensitive tests: Linux WebKit runs significantly slower than Chromium and Firefox.
  • Complex single-page applications: Heavy client-side rendering takes noticeably longer under software rendering.
  • Visual regression tests: Linux font rendering differs from macOS Safari, so pixel-diff screenshots rarely match macOS baselines.
  • Media-heavy pages: Video and audio playback relies on Linux codecs, which are more limited than on macOS.

Not supported

  • Branded Apple Safari (Playwright uses its own WebKit build, not Apple Safari)
  • GPU-accelerated rendering and WebGL-heavy graphics (runners use software rendering only)
  • Real-time video or audio playback and proprietary media codecs
  • Browser extensions (not supported in Playwright's WebKit)
  • Architectures other than Linux ARM64
  • Production synthetic monitoring

Known limitations

Performance

WebKit on Linux runs noticeably slower than Chromium and Firefox in Endform's software-rendered environment, particularly on initial page loads, heavy client-side rendering, and complex single-page applications.

This slowdown is a known upstream limitation of Playwright's WebKit build on Linux, tracked in Playwright #31481 and Playwright #18119. Set the WebKit project timeout to 90 to 120 seconds, and avoid tight hardcoded timeouts inside tests.

Differences from macOS Safari

Playwright's Linux WebKit build does not behave identically to Safari on macOS:

  • Font rendering differs from macOS, which affects screenshot comparisons.
  • Available media codecs vary substantially across operating systems, and proprietary media formats generally do not play on Linux WebKit, as noted in the Playwright WebKit documentation.
  • Some CSS rendering details and JavaScript performance characteristics differ from macOS Safari.

When to use WebKit

Start with Chromium (and Firefox if needed) for your primary test coverage, and add WebKit to validate critical user journeys where Safari compatibility matters most.

ScenarioRecommendation
Primary test suiteUse Chromium (and Firefox if needed) for fast day-to-day feedback
Cross-browser validationGood fit for critical user journeys
Safari compatibilityBest available option on Linux runners
Visual regressionExpect font and rendering differences from macOS Safari
Performance testingUse Chromium instead
Production monitoringNot recommended while support is experimental

Practical tips

  • Scope to critical paths: Use testMatch or tags to run your highest-value flows in WebKit rather than duplicating your entire suite.
  • Keep independent tests parallel: When tests do not share mutable state, keep fullyParallel: true so Endform fans slow WebKit tests out across separate runners instead of chaining them sequentially on one machine. See Fully parallel testing.
  • Avoid tight timings and macOS screenshot baselines: Rely on Playwright's auto-waiting assertions with a generous project timeout, and skip screenshot assertions that depend on macOS font rendering.

Last updated