How do I define NOBLOGREDIRECT to main site?

I'm working on a multisite but the subdomains are for templates, not a registered user type of site. So if someone goes to a page that doesn't exist, I want them to be redirected back to the main site, instead of seeing a portion of the main site with "Registration is disabled."

I've searched this forum. I'm sure the answer is simple.
I looked at wp-config.php and I see where the "Defines" are, but I don't know what code to insert.

Any help resolving this is greatly appreciated :slight_smile: