---
schema_version: "1"
id: e35a7bdd7d4fc986bda40c0d2ea749a09e82f3f34acdad2acb9df79bd0ab36ca
title: pageReference Types
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/platform/aura-platform/guides/aura/components/components-navigation-page-definitions.md
canonical_url: https://developer.salesforce.com/docs/platform/aura-platform/guide/components-navigation-page-definitions.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: c3792564595979c2769e9a1c18571bf4922238e168614a73e3520cda1e3f7841
products:
  - Lightning Aura Components Developer Guide
  - Platform Developer Content
---

# pageReference Types

To navigate in Lightning Experience, Experience Builder sites, or the Salesforce mobile app, define a `PageReference` object. The `pageReference` type generates a unique URL format and defines attributes that apply to all pages of that type. For Experience Builder sites, depending on the page type, the `pageReference` property requirements can differ between LWR sites and Aura sites.

The following types are supported.

- App
- External Record Page
- External Record Relationship Page
- Knowledge Article
- Lightning Component (must implement `lightning:isUrlAddressable`)
- Login Page
- Managed Content Page (Salesforce CMS)
- Named Page (Experience Cloud)
- Named Page (Standard)
- Navigation Item Page
- Object Page
- Record Page
- Record Relationship Page
- Standard Flow
- Web Page

**note:** `PageReference` objects are supported on a limited basis for Experience Builder sites, as noted for each type.

## App Type

A standard or custom app available from the App Launcher in an org. Use this `pageReference` type to create custom navigation components that take users to a specific app or page within the app. Connected apps aren’t supported.

**note:** If you’re navigating users to a different app using a `pageRef`, the app opens in the same window by default. To open a link in a new tab, see the [navigation service documentation](https://developer.salesforce.com/docs/component-library/bundle/lightning:navigation/documentation).

**Type**

```javascript
standard__app;
```

**Experience:** Lightning Experience

**Type Attributes**

| Property    | Type          | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  | Required? |
| ----------- | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------- |
| `appTarget` | String        | App that you’re navigating to. Pass either the `appId` or `appDeveloperName` to the `appTarget`. The `appId` is the `DurableId` field on the `AppDefinition` sObject. The `appDeveloperName` value is formed by concatenating the app’s namespace with the developer name. To find the app’s developer name, navigate to the App Manager in Setup and look in the Developer Name column. For standard apps, the namespace is `standard__`. For custom apps, it’s `c__`. For managed packages, it’s the namespace registered for the package. | Yes       |
| pageRef     | PageReference | Identifies a specific location in the app you’re navigating to. Pass in the `pageRef` and applicable attributes for that `pageRef` type.                                                                                                                                                                                                                                                                                                                                                                                                     | No        |

**Example Navigating to an App**

```javascript
{
    type: "standard__app",
    attributes: {
        appTarget: "standard__Sales",
    }
}
```

**Example Navigating to a Record in an App**

```javascript
{
    type: "standard__app",
    attributes: {
        appTarget: "standard__LightningSales",
        pageRef: {
            type: "standard__recordPage",
            attributes: {
                recordId: "001xx000003DGg0AAG",
                objectApiName: "Account",
                actionName: "view"
            }
        }
    }
}
```

**URL Format**

```html
/lightning/app/{appTarget}{...pageRef}
```

**URL Format Examples**

Navigate to the app’s homepage using the `appId`

```html
/lightning/app/06mRM0000008dNrYAI
```

Navigate to an object record’s page in the app using the `appId`

```html
/lightning/app/06mRM0000008dNrYAI/o/Case/home
```

Navigate to the app’s homepage using the `appDeveloperName`

```html
/lightning/app/standard__LightningSales
```

Navigate to an object record’s page in the app using the `appDeveloperName`

```html
/lightning/app/standard__LightningSales/o/Case/home
```

## External Record Page

A page that interacts with an external record. Currently supports CMS Connect pages.

**Type**

```javascript
comm__externalRecordPage;
```

**Experience:** Experience Builder Aura Sites

**Type Attributes**

| Property     | Type   | Description                                                              | Required? |
| ------------ | ------ | ------------------------------------------------------------------------ | --------- |
| `recordId`   | String | External record ID.                                                      |           |
| `objectType` | String | External record type. Currently only supports `cms` for CMS Connect.     |           |
| `objectInfo` | Object | Additional information used to identify the record for the `objectType`. |           |

**Example**

```javascript
{
    type: "comm__externalRecordPage",
    attributes: {
        recordId: "26",
        objectType: "cms",
        objectInfo: {
            cmsSourceName: "blog",
            cmsTypeName: "feed",
        }
    },
    state: {
        recordName: "coffee-on-the-world-map",
    }
}
```

**URL Format**

```html
/{baseUrl}/{recordId}/{recordName}
```

## External Record Relationship Page

A page that interacts with an external relationship on a particular record in the org. Currently only supports Quip Related List page.

**Type**

```javascript
comm__externalRecordRelationshipPage;
```

**Experience:** Experience Builder Aura Sites

**Type Attributes**

| Property     | Type   | Description                                                         | Required? |
| ------------ | ------ | ------------------------------------------------------------------- | --------- |
| `recordId`   | String | The 18 character record ID.                                         |           |
| `objectType` | String | External record type. Currently only supports `quip` for Quip docs. |           |

**Example**

```javascript
{
    type: "comm__externalRecordRelationshipPage",
    attributes: {
        recordId: "001xx000003DGg0AAG",
        objectType: "quip",

```

**URL Format**

```html
/{baseUrl}/{recordId}
```

## Lightning Component Type

A Lightning component that implements the `lightning:isUrlAddressable` interface, which enables the component to be navigated directly via URL.

**Type**

```javascript
standard__component;
```

**Experience:** Lightning Experience, Salesforce Mobile App

**Type Attributes**

| Property        | Type   | Description                                                            | Required? |
| --------------- | ------ | ---------------------------------------------------------------------- | --------- |
| `componentName` | String | The Lightning component name in the format `namespace__componentName`. | Yes       |

**Example**

```javascript
{
    "type": "standard__component",
    "attributes": {
        "componentName": "c__MyLightningComponent"
    },
    "state": {
        "c__myAttr": "attrValue"
    }
}
```

You can pass any key and value in the `state` object. The key must include a namespace, and the value must be a string. If you don’t have a registered namespace, add the default namespace of `c__`.

**URL Format**

```html
/cmp/{componentName}?c__myAttr=attrValue
```

## Login Page Type

An authentication for an Experience Builder site.

**Type**

```javascript
comm__loginPage;
```

**Experience:** Experience Builder sites

**Type Attributes**

| Property     | Type   | Description                                                                      | Required |
| ------------ | ------ | -------------------------------------------------------------------------------- | -------- |
| `actionName` | String | A login-related action to be performed. Possible values are `login` or `logout`. | Yes      |

**note:** You can only navigate to `comm__namedPages` when you're calling navigate from: Login, Check Password, Forgot Password, Login Error, and Register. Other page references don't work from these pages.

**Example**

```javascript
{
    type: "comm__loginPage",
    attributes: {
        actionName: "login"
    }
}
```

## Knowledge Article Page Type

A page that interacts with a Knowledge Article record.

**Type**

```javascript
standard__knowledgeArticlePage;
```

**Experience:** Lightning Experience, Experience Builder sites, Salesforce Mobile App

**Type Attributes**

| Property      | Type   | Description                                                                                                        | Required? |
| ------------- | ------ | ------------------------------------------------------------------------------------------------------------------ | --------- |
| `articleType` | String | The `ArticleType` API name of the Knowledge Article record. In Experience Builder sites, `articleType` is ignored. | Yes       |
| `urlName`     | String | The value of the `urlName` field on the target KnowledgeArticleVersion record. The `urlName` is the article's URL. | Yes       |

**Example**

```javascript
{
    "type": "standard__knowledgeArticlePage",
    "attributes": {
        "articleType": "Briefings",
        "urlName": "February-2017"
    }
}
```

**URL Format:**

```html
/articles/{articleType}/{urlName}
```

**URL Format (Experience Cloud)**

```html
/article/{urlName}
```

## Managed Content Page (Salesforce CMS)

A CMS content page in an Experience Builder site with a unique name.

**Type**

```javascript
standard__managedContentPage;
```

**Experience:** Experience Builder sites

**Type Attributes**

| Property          | Type   | Description                                         | Required? |
| ----------------- | ------ | --------------------------------------------------- | --------- |
| `contentTypeName` | String | The name of the Salesforce CMS content type.        | Yes       |
| `contentKey`      |        | The unique content key that identifies CMS content. | Yes       |

**Example**

```javascript
{
    type: 'standard__managedContentPage',
    attributes : {
        'contentTypeName': 'news',
        'contentKey': 'MCOMALJDRAYFFSFPNBQONYXVFHOA'
    }
}
```

**URL Format**

```html
/:urlAlias
```

## Named Page Type (Experience Cloud)

A standard page in an Experience Builder site with a unique name. If an error occurs, the error view loads and the URL isn’t updated.

**Type**

```javascript
comm__namedPage;
```

**Experience:**

**:** Experience Builder sites

**Type Attributes**

| Property | Type   | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         | Required? |
| -------- | ------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------- |
| `name`   | String | The unique name of the Experience Builder site page. The value for `name` is the API Name value for a supported page. The **API Name** field can only be defined when a new page is being created, and must be unique. If the **API Name** isn’t defined upon page creation, it’s automatically generated. The value of `home` is reserved for the landing page of any Experience Builder site in your org. Supported pages are Home, Account Management, Contact Support, Error, Login, My Account, Top Articles, Topic Catalog, and custom pages. | Yes       |

**Example**

```javascript
{
    type: "comm__namedPage",
    attributes: {
        name: "Home"
    }
}
```

**URL Format**

```html
/{URL as defined on the page’s properties}
```

## Named Page Type (Standard)

A standard page with a unique name. If an error occurs, the error view loads and the URL isn’t updated.

**Type**

```javascript
standard__namedPage;
```

**Experience:** Lightning Experience, Salesforce Mobile App

**Type Attributes**

| Property   | Type   | Description                                                                                                      | Required? |
| ---------- | ------ | ---------------------------------------------------------------------------------------------------------------- | --------- |
| `pageName` | String | The unique name of the page. Possible values are `home`, `chatter`, `today`, `dataAssessment`, or `filePreview`. | Yes       |

**Example**

```javascript
{
    "type": "standard__namedPage",
    "attributes": {
        "pageName": "home"
    }
}
```

**URL Format**

```html
/page/{pageName}
```

## Navigation Item Page Type

A page that displays the content mapped to a CustomTab. Visualforce tabs, web tabs, Lightning Pages, and Lightning Component tabs are supported.

**Type**

```javascript
standard__navItemPage;
```

**Experience:** Lightning Experience, Salesforce Mobile App

**Type Attributes**

| Property  | Type   | Description                       | Required? |
| --------- | ------ | --------------------------------- | --------- |
| `apiName` | String | The unique name of the CustomTab. | Yes       |

**Example**

```javascript
{
    "type": "standard__navItemPage",
    "attributes": {
        "apiName": "MyCustomTabName"
    }
}
```

**URL Format**

```html
/n/{apiName}
```

## Object Page Type

A page that interacts with a standard or custom object in the org and supports standard actions for that object.

**note:** The `standard__objectPage` type replaces the `force:navigateToObjectHome` and the `force:navigateToList` events.

**Type**

```javascript
standard__objectPage;
```

**Experience:** Lightning Experience, Experience Builder sites, Salesforce Mobile App

**Type Attributes**

| Property        | Type   | Description                                                                                                                                 | Required? |
| --------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------- | --------- |
| `actionName`    | String | The action name to invoke. Valid values include `home`, `list`, and `new`. In Experience Builder sites, `list` and `home` are the same.     | Yes       |
| `objectApiName` | String | The API name of the standard or custom object. For custom objects that are part of a managed package, prefix the custom object with `ns__`. | Yes       |

**State**

| Property             | Type   | Description                                                                                                                                                                                                                                                                                                  | Supported Actions     | Required? |
| -------------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | --------------------- | --------- |
| `filterName`         | String | ID or developer name of the object page. Default is `Recent`.                                                                                                                                                                                                                                                | `list`                | No        |
| `defaultFieldValues` | String | List of key-value pairs for the default field values that you’re passing. This list is generated by the `lightning:pageReferenceUtils` component. See [lightning:pageReferenceUtils](https://developer.salesforce.com/docs/component-library/bundle/lightning:pageReferenceUtils/documentation) for details. | `new`                 | No        |
| `nooverride`         | String | To use a standard action, assign this property any value, such as `1`. To use an override action, don’t include this property at all.                                                                                                                                                                        | `home`, `list`, `new` | No        |

**Standard Object Example**

```javascript
// Opens the case home page.
{
    "type": "standard__objectPage",
    "attributes": {
        "objectApiName": "Case",
        "actionName": "home"
    }
}
```

**Navigate to a Specific List View Example**

```javascript
// Navigates to account list with the filter set to RecentlyViewedAccounts.
{
    "type": "standard__objectPage",
    "attributes": {
        "objectApiName": "ns__Widget__c",
        "actionName": "list"
    },
    "state": {
        "filterName": "RecentlyViewedAccounts"
  }
}
```

**Navigate to a Record Create Page with Default Field Values**

```javascript
// Navigates to a new account object using these default field values.
//{
//    Name: "Salesforce, #1=CRM",
//    OwnerId: "005XXXXXXXXXXXXXXX",
//    AccountNumber: "ACXXXX",
//    NumberOfEmployees: 35000,
//    CustomCheckbox__c: true
//}
{
    type: "standard__objectPage",
    attributes: {
        objectApiName: "Account",
        actionName: "new"
    },
    state: {
        defaultFieldValues = "AccountNumber=ACXXXX,CustomCheckbox__c=true,Name=Salesforce%2C%20%231%3DCRM,NumberOfEmployees=35000,OwnerId=005XXXXXXXXXXXXXXX",
        nooverride: "1"
    }
}
```

**URL Format**

```html
/o/{objectApiName}/{actionName} /o/{objectApiName}/{actionName}?filterName=Recent
```

**URL Format (Experience Cloud)**

```html
/recordlist/{objectApiName} /{baseUrl}/{objectApiName}
```

## Record Page Type

A page that interacts with a record in the org and supports standard actions for that record.

**note:** The `standard__recordPage` type replaces the `force:navigateToSObject` event.

**Type**

```javascript
standard__recordPage;
```

**Experience:** Lightning Experience, Experience Builder sites, Salesforce Mobile App

**Type Attributes**

| Property        | Type   | Description                                                                                                                                       | Required?                                                                |
| --------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------ |
| `actionName`    | String | The action name to invoke. Valid values include `clone`, `edit`, and `view`. Experience Builder sites don’t support the values `clone` or `edit`. | Yes                                                                      |
| `objectApiName` | String | The API name of the record’s object. Optional for lookups.                                                                                        | Yes, for Experience Builder LWR sites only No, for all other experiences |
| `recordId`      | String | The 18 character record ID.                                                                                                                       | Yes                                                                      |

**State**

| Property     | Type   | Description                                                                                                                           | Required? |
| ------------ | ------ | ------------------------------------------------------------------------------------------------------------------------------------- | --------- |
| `nooverride` | String | To use a standard action, assign this property any value, such as `1`. To use an override action, don’t include this property at all. | No        |

**Example**

```javascript
{
       "type": "standard__recordPage",
       "attributes": {
           "recordId": "001xx000003DGg0AAG",
           "objectApiName": "PersonAccount",
           "actionName": "view"
       }
}
```

**URL Format**

```html
/r/{objectApiName}/{recordId}/{actionName} /r/{recordId}/{actionName}
```

**URL Format (Experience Cloud)**

```html
/detail/{recordId} /{baseUrl}/{recordId}
```

## Record Relationship Page Type

A page that interacts with a relationship on a particular record in the org. Only related lists are supported.

**note:** The `standard__recordRelationshipPage` type replaces the `force:navigateToRelatedList` event.

**Type**

```javascript
standard__recordRelationshipPage;
```

**Experience:** Lightning Experience, Experience Builder sites, Salesforce Mobile App

**Type Attributes**

| Property              | Type   | Description                                                                     | Required?                                                                |
| --------------------- | ------ | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------ |
| `actionName`          | String | The action name to invoke. Only `view` is supported.                            | Yes                                                                      |
| `objectApiName`       | String | The API name of the object that defines the relationship. Optional for lookups. | Yes, for Experience Builder LWR sites only No, for all other experiences |
| `recordId`            | String | The 18 character record ID of the record that defines the relationship.         | Yes                                                                      |
| `relationshipApiName` | String | The API name of the object’s relationship field.                                | Yes                                                                      |

**Example**

```javascript
{
    "type": "standard__recordRelationshipPage",
    "attributes": {
        "recordId": "500xx000000Ykt4AAC",
        "objectApiName": "Case",
        "relationshipApiName": "CaseComments",
        "actionName": "view"
    }
}
```

**URL Format**

```html
/r/{objectApiName}/{recordId}/related/{relationshipApiName}/{actionName}
/r/{recordId}/related/{relationshipApiName}/{actionName}
```

**URL Format (Experience Cloud)**

```html
/relatedlist/{recordId}/{relationshipApiName} /{baseUrl}/related/{recordId}/{relationshipApiName}
```

## Standard Flow Type

A page that runs an active screen or autolaunched flow.

**Type**

```javascript
standard__flow;
```

**Experience:** Lightning Experience

**Type Attributes**

| Property  | Type   | Description                                                   | Required? |
| --------- | ------ | ------------------------------------------------------------- | --------- |
| `devName` | String | The flow name (`flowName`or `namespace__flowName`).           | Yes       |
| `retURL`  | String | The relative URL to redirect users to when the flow finishes. | No        |

**Example**

You can pass input variable values to the flow in the state object. The key must be prefixed by `flow__`. Record variables, Apex-Defined variables, and collection variables are not supported.

```javascript
{
  "type": "standard__flow",
  "attributes": {
    "devName": "MyFlow"
  },
  "state": {
    "flow__myInputVar": "inputVarValue"
    "retURL" : "lightning/page/home"
  }
}
```

**URL Format**

```html
/lightning/flow/{flowName}?flow__myInputVar=inputVarValue&retUrl=lightning%2Fpage%2Fhome
```

## Web Page

An external URL. Navigate to web pages using the `lightning:navigate` component with the `standard__webPage` page type instead of using `force:navigateToURL`. In Aura sites, certain internal Salesforce URLs have site-specific processing. For example, `/apex/` URLs are translated to `/sfdcpage/`. The Visualforce page is embedded within the site in an iFrame, which is the same behavior as with `force:navigateToURL`. Use `window.open` if you want to go straight to the URL, such as opening `/apex/` directly in a new tab.

**important:** On orgs running API version 68 or later with Lightning Web Security for Aura enabled, opening a same-origin Salesforce URL in a new tab using `window.open()` with `_blank` results in a `LockerSecurityError`.

For same-origin downloads and navigation, use this programmatic anchor click.

```nolang
const a = document.createElement('a');
a.href = url;                   // /apex/... clears the href denylist
a.target = '_blank';            // or omit for same-tab
a.rel = 'noopener noreferrer';
a.click();                     // keep it detached; do NOT append to body/head
```

**Type**

```javascript
standard__webPage;
```

**Experience:** Lightning Experience, Salesforce Mobile App

**Attributes**

| Property | Type   | Description                               | Required |
| -------- | ------ | ----------------------------------------- | -------- |
| `url`    | String | The URL of the page you’re navigating to. | Yes      |

**Example**

```javascript
{
    "type": "standard__webPage",
    "attributes": {
        "url": "https://salesforce.com"
    }
}
```

**URL Format:** A web page opens as is in a new tab, so it doesn’t have a URL format.

**See Also**

- [_LWR Sites for Experience Cloud:_ Lightning Navigation](https://developer.salesforce.com/docs/atlas.en-us.exp_cloud_lwr.meta/exp_cloud_lwr/get_started_comp_navigation.htm)
