Share via


Friendly URLs and Search Results

Publishing Portal and Enterprise Wiki sites feature the convenience of Friendly URLs, which work in tandem with Managed Navigation to replace location-specific URLs with location-agnostic, more human-readable URLs.

In this example, the page https://contoso.sharepoint.com/sites/Departments/Pages/Information%20Technology.aspx is referenced by the navigation term 'IT'.

By default, the Friendly URL is derived from the name of the navigation term itself, though the Friendly URL can be modified in the Term Store Management Tool. Here, the Friendly URL is changed from https://contoso.sharepoint.com/sites/Departments/IT to https://contoso.sharepoint.com/sites/Departments/Info-Technology.

b1

When Managed Navigation is enabled in Site Settings -> Look and Feel -> Navigation, Friendly URLs are created automatically as Publishing Content Type pages are added to the site.

b2

More information about Managed Navigation and Friendly URLs can be found on the Office Support site. (Reference)

While many customers utilize Friendly URLs as part of their content navigation strategy, it is important to be aware of some common issues that can occur.

Physical URLs hidden from Search results

If you look at Library Settings for a Pages library provisioned with a Publishing site, you’ll notice the following column.

b6

The “Hide physical URLs from search” property determines whether search results will include keywords matching the Physical URL of the page. If this is set to “Yes”, then any attempt to search on the actual file name or file path won’t return this page.

b3If you need to search for pages by physical location rather than Friendly URL, you can set “Hide physical URLs from search” to "No".

  1. Edit the properties of the ASPX page.
    • In the Pages library, select the ASPX page, open its ECB (ellipsis) menu, and click “Properties”.
    • Or, select the ASPX page, click the “Files” ribbon, then click “Edit Properties”.
  2. Uncheck the option “Hide physical URL from search” for each page
  3. Re-index the Pages library by browsing to Library Settings -> Advanced Settings -> Reindex This Library.

Again, this procedure applies only to Publishing Content Type pages. (Reference) Also, keep in mind that incremental search crawl can take much more time for Publishing Content Type pages than for other content types due to the search crawl accessing the term store. If a re-index operation typically takes 5 to 15 minutes, expect re-indexing of a Pages library on a Publishing site to take 1-2 hours.

Creating pages from Site Ribbon v/s Pages Library

Consider these different ways of creating an ASPX page in the Pages library.

  1. Site Ribbon.
    • While viewing any page in the site, click the Gear -> Show Ribbon. Then, click the Pages ribbon, locate the Edit section of the ribbon, and click New.
    • b5
  2. Pages Library.
    • While viewing the Pages library All Documents view, either click the New button, or click the Files ribbon followed by New Document.
    • b4

These two procedures have different effects that are summarized below.

Site Ribbon Pages Library
·         “Hide physical URLs from search” set to “Yes” ·         “Hide physical URLs from search” set to “No”
·         Navigation term created automatically, if that option is enabled in Site Settings -> Navigation ·         If needed, the term must be created manually from the Term Store Management Tool
·         Friendly URL assigned automatically ·         Friendly URL must be assigned to a term manually in the Term Store Navigation tool

Content Authors might become confused by this divergent behavior. If this is the case, you can disable the options “Create Friendly URLs for new pages automatically” and “Add new pages to navigation automatically” in Site Settings -> Navigation. This means that Managed Navigation will need to be built manually.