Programmed on a web server’s HTACCESS File, these pages are useful for SEO because:
As you can see from the example above, they provide links back to the main domain, ensuring users and search engines can access other pages on your site.
They are a great “failsafe” mechanism for SEO as the default/generic 404 error page that gets displayed contains no links back to the site and can be a “dead end” for users and spiders; this can hurt crawlability of the site if a 404 page hasn’t fallen from the index, yet.
They are helpful if you have any broken links on your site that you haven’t discovered which will, again, aid in crawlability and user experience.
They can give you the ability to drive more traffic to pages on your site that are very popular targets for search, by making that page’s link stand out from the rest. You can highlight it or make it the focus of the custom 404 page.