<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: -",
    "macOS: 26.0.0 -",
    "visionOS: 26.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "WebKit",
  "identifier" : "/documentation/WebKit/WebPage/load(_:)-8wfiq",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "WebKit"
    ],
    "preciseIdentifier" : "s:6WebKit0A4PageC4loadyQr10Foundation3URLVSgF"
  },
  "title" : "load(_:)"
}
-->

# load(_:)

Loads the web content that the specified URL references and navigates to that content.

```
@discardableResult @MainActor final func load(_ url: URL?) -> some AsyncSequence<WebPage.NavigationEvent, any Error>
```

## Parameters

`url`

The URL to load. If this is `nil`, an error will be immediately thrown from the returned sequence.

## Return Value

An async sequence you use to track the loading progress of the navigation. If the `Task` enclosing the sequence is cancelled, the page will stop loading all resources.

## Discussion

Use this method to load a page from a local or network-based URL. For example, you might use this method
to navigate to a network-based webpage.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)