What is WebKit?
Definition WebKit is the open-source browser engine developed mainly by Apple that powers Safari on Mac, iPhone and iPad. On iOS and iPadOS, Apple's App Store rules have required every browser to use WebKit, so Chrome, Firefox and Edge on iPhone render pages with it too; since iOS 17.4 the EU allows alternative engines, but most iPhone browsers still use WebKit. It is why a page can look different on iPhone than in Chrome on Android.
Try it: Test a website on iPhone (WebKit)
Where did WebKit come from?
Apple forked WebKit from the KDE project's KHTML engine and released it with Safari in 2003. Google used WebKit in Chrome until 2013, when it forked it into Blink, the engine of Chromium. Since then the two engines have developed separately, though most web standards behave the same in both.
What does WebKit do differently?
Most differences web developers meet on iPhone come from WebKit and iOS:
- Viewport height. Safari's collapsing toolbar is the classic reason
100vhis taller than the screen; see viewport units. - Form fields. Safari zooms into inputs with a font size under 16px when they are focused, and draws native iOS controls.
- Zoom. Since iOS 10, pinch-zoom works even with
user-scalable=no. - Fonts. San Francisco is the system font;
system-uilooks different from Android's Roboto. - Prefixes and timing. Some features need
-webkit-prefixes or arrive in a different Safari version than in Chrome. Because Safari is updated with iOS, users on older iPhones run older WebKit. - Metrics. The Layout Instability API behind CLS is not available, and Google's Chrome UX Report doesn't include Safari visitors.
Testing in WebKit
Chrome DevTools device emulation uses Chromium even when you pick an iPhone, so it can't show WebKit rendering. Options are a real iPhone or iPad, Safari on a Mac with Responsive Design Mode, Apple's iOS Simulator in Xcode, or a service that runs WebKit itself. Developers can test in WebKit with Playwright, which ships a WebKit build for Linux, Windows and macOS.
WebKit in MobileCheck
MobileCheck renders iPhones and iPads in WebKit, the engine behind Safari, and Android devices in Chromium. WebKit on a server is not a real iPhone: it catches most Safari layout and CSS differences, but it has no Apple system fonts (system-ui falls back to another font), no native iOS form controls, no focus zoom and no on-screen keyboard, so check those on a device.
Related terms
Guides and tools
- Test a website on iPhone (WebKit)
- Safari vs Chrome: the same page side by side
- iPhone simulator online