I should note that, once I put the WKWebView into the window, there is an error that I hadn't noticed before: error: Class Unavailable: WKWebView before macOS 10.12 (NSCoding support was broken in previous versions) So I would have to drop support for 10.9-10.11 to use WKWebView, so I really need to work out how to do this.