Nice question, its common to have URL and we wish to have redirect the wrongly typed URL to your home page.
I need little more information which CMS or platform you are using, it may be vary according to the server you are using, and i found the site where you can do set your costume error message or site setting to generate the code for your error.
you can visit
as per your quarry, i think you want to redirect the pages from 404 page to your home page right.
its not about wrong/mistyped URL its about URL which is not in your site, so here is code i could generated that you can enter in your .htaccess file
//Custom 404 errors
I hope this will help you.