Earlier this year, we explained how to find 404 pages in Google Analytics. But just because there are no 404 pageviews in Google Analytics, does not mean your site is not prone to technical SEO issues.
Your web server can generate an XML sitemap - a file containing URLs of all your site's pages. You can submit this file through Google Search Console (from now on, GSC) or reference it in your robots.txt.
Search engines periodically visit XML sitemaps to crawl and index new pages. The XML sitemap might reference URLs of pages that no longer exist if the web server does not keep it up to date.
To see if your XML sitemap file references non-existent pages, visit the Coverage report in GSC and look for the "Submitted URL not found (404)" error.
Clicking on that error reveals 404 URLs that you need to remove from your XML sitemap.
Remove 404 URLs from your XML sitemap and resubmit it to Google through its Search Console. Once done, don't forget to click on the Validate Fix button to stop the "Submitted URL not found (404)" error from appearing in your reports.
This is a perfect example of how even if you think everything is running smoothly, there might be some lingering issues that need your attention. Remember, your digital eco-system is full of stored files and catalogues just like this, sometimes in places you'd never think to look! It's a good idea to identify and maintain these repositories as frequently as you can so that you are always in full control of your digital assets. Happy optimizing!