SharePoint 2013 is shipped with a default "Page not found" Error page in "Pages" library in publishing Sites (http://intranet.crescent.com/Pages/PageNotFoundError.aspx) which works automatically when a user hits a non-existent URLs.
We can either customize this page or create our own page and set as a page not found error page. Here are the steps to create a custom 404 page not found error page:
- Go to Site Contents, Pages Library and Create New Error Page
- Customize the error page with your own styles and images
- Use PowerShell script to set the new page as default page not found error page.
$site = Get-SPSite "http://your-sharepoint-site-coll-url" $site.filenotfoundurl = "/Pages/PageNotFound.aspx" #Relative path
Using SharePoint Designer to set Custom Page not found error page:
You can also use SharePoint designer to set the custom page not found error page: Here is how:
- Open your SharePoint 2013 Site in SharePoint Designer 2013
- Select the Site object in the left side treeview, Click on Site Options button in the ribbon
- Assign the "vti_filenotfoundpage" property of the site to a Custom Error Page that you created.
- Don't forget to hit Save button to commit your changes.
You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.