SharePoint Online Tutorial

newbietechie_sharepoint-icon-x256

Create Custom 404 Error Page For SharePoint Online
Without Writing Any Code

In this post I will share how to create a custom 404 ( or page not found ) error page for SharePoint Online Team Site. The process is simple and straight forward but requires little trick. Moreover this process doesn’t require you to write any code, you can use the default SharePoint page creation tool to create your own 404 error page. However, if you wish to write code to customize the page, you can do that as well. So without any delay, check below and find out how to design the 404 error page.

Why Do you need a custom 404 page in SharePoint?

Well the default 404 page in SharePoint may not be appropriate and you may want to use a better user experience for your customers. In such case you need to create a custom 404 error page, which will be displayed when users put a wrong URL.
The benefit of having a custom 404 page that your customers will have better aesthetic pleasure while using the SharePoint site.

without custom 404 sharepoint page newbietechie.com
Default SharePoint 404 page

Prerequisites

You will need the following to complete this tutorial

  1. Site collection admin access in the SharePoint site
  2. SharePoint Designer 2013

If you have both of the above then follow the below steps to create your custom page not found page in SharePoint.

Steps

#1. Create a new SharePoint page and customize it as you want

The first step for creating a custom 404 page is to have a SharePoint page ready for the same purpose. So, create a new SharePoint page and customize it.
To keep this tutorial simple, I have not shown how to add custom JavaScript to read the URL and give a corresponding response.

As mentioned above I have created a simple page(image below) and named it as Page Not Found(you can name it as you wish). As you can see I have customized it with some basic images and texts.
After creating the page, copy the link from the navigation bar as below
/sites/TestSite/SitePages/PageNotFoundError.aspx

custom 404 page SharePoint online
SharePoint page created as custom 404 error page

#2. Connect To Site from SP designer

Now connect and open the SharePoint site in SharePoint designer

Connect to SP designer newbietechie
connect to SP designer

#3. Open the Site Options and Modify it

After connecting to the site using SharePoint designer, open the site options pane from the top menu. Then check if the below parameter exists, if it exists then your site already has a 404 error page configured. On the other hand, if the parameter doesn’t exist then add a new parameter and set the value as the site link of the page you copied in first step. Follow the images below to understand better.
Parameter name: vti_filenotfoundpage
Value: /sites/TestSite/SitePages/PageNotFoundError.aspx
note: for you the value might be different as it depends on the page link

Designer site options newbietechie to create custom 404 sharepoint page
Open Site Options
create a custom 404 sharepoint page by adding vtipagenotfound property newbietechie
Add the parameter

That’s it, click apply and okay.

#Final. Test the 404 page

Now to test the 404 page, type a wrong URL under that SharePoint site. If you have done everything correctly then you should be able to see as below.

testing custom 404 sharepoint page wrong url newbietechie.com
Put wrong URL to test
custom 404 sharepoint page redirected newbietechie.com redirected
Redirected to 404 page

#Next Steps

That’s all I have for creating a custom 404 SharePoint page. However there other ways as well such as using PowerShell or using tools other than SharePoint designer. Below are some links which you can take a look if you are interested.
Thank you, I hope you now have a custom 404 page for your site.

SharePoint Online: How to Implement Custom 404 Page Not Found Error Page? Other ways
https://www.sharepointdiary.com/2019/02/implement-custom-page-not-found-error-page-in-sharepoint-online.html#ixzz78v43uzsE
Implementing 404 custom page on Communication Site

Please Help us Grow!

I hope you have found this article helpful. If you are happy with the document, please use the below links when you buy something from Amazon to help us grow.

Ways to Help

Amazon Affiliate Links

How this works?

Amazon affiliate program gives a small (%)share of price to the referrers, so feel free to buy anything.
Below are some Amazon affiliate links, if you open amazon application/website using these links and buy something, (it can be one of the below items or anything of your choice) Then Amazon will give us a little percentage(%) of the money you spend on Amazon. To know more check this document.

$350-Best Student laptop
Amazon In, Amazon US

$600-Work laptop
Amazon In, Amazon US

$989– High performance
Amazon In, Amazon US

Headset – $15.99
Amazon In, Amazon US

Lightspeed Mouse – $39
Amazon In, Amazon US

Keyboard – $29
Amazon In, Amazon US

The Psychology of Money
Amazon In, Amazon

Atomic Habits:
Amazon In, Amazon

Find Balance and Purpose in Life
Amazon In, Amazon

$30, Smart Watch for Smart you
Amazon In, Amazon US, Amazon UK

Work comfortably with $110
Amazon In, Amazon US, Amazon UK

Exercise at home
Amazon In, Amazon US, Amazon UK

Thank you
For your Contribution


Newbietechie.com
Author @ramizmollahmd

About Ramiz

Ramiz is a professional working in an MNC as a business and technology consultant for quite a few years now. Ramiz is proficient in various Microsoft tools and technologies. He is a tech enthusiast and an active blogger. Ramiz spends his free time playing games or watching movies. He writes blogs to share his knowledge with the world and to make it a better place to live.