If this tutorial is not what you were looking for, you still have any questions, suggestions or concerns - feel free to let us know. Please help us to serve you better!

Your Name

Your Email

Your Message (required)

captcha

Featured templates

Joomla 3.x. How to add custom 404 page

Hello! This tutorial will show you how to add a custom 404 page in Joomla 3.

Joomla 3.x. How to add custom 404 page

  1. Create an ‘uncategorized’ article in Joomla to serve as your 404 Page, save and close it:

    Joomla_3.x_ How_to_add_custom_404_page_1

  2. On the right side, under ID, you can see an article identification number, please copy and save it.

  3. Create a menu item, which links to the new 404 Article and ‘apply’ changes. Copy menu id number and save it.

  4. Type your site URL into browser address bar and add to it the link in the following format:

    index.php?option=com_content&view=article&id=yy&Itemid=xx
    

    In that URL “yy” is the ID of the desired article, in our case, it is the ID of the newly created article. “xx” is the ID of menu item.

    Save the link starting from (index.php?option…):

    Joomla_3.x. How_to_add_custom_404_page_2

  5. In your Joomla installation directory reach templates/themeXXX/error.php file.

    Edit the error.php file as shown below, locate this line of code:

    if (($this->error->getCode()) == '404') {
    header('Location: ' . JRoute::_("index.php?option=com_content&view=article&id=xx&Itemid=xx", false));
    exit;
    }

    Replace the path to the page (index.php?option..) with the link that you’ve saved earlier:

    Joomla_3.x_ How_to_add_custom_404_page_3

Feel free to check the detailed video tutorial below:

Joomla 3.x. How to add custom 404 page