How to suppress default HtmlException? I need to turn off 404 &amp; related Exceptions. Need to handle it in custom way.

I've implemented an EventSubscriber with listener for kernel.exception event.

But $event-&gt;setException() cannot receive NULL.

Any ideas?
This is the correct approach. Don't do all the work yourself, extend  DefaultExceptionHtmlSubscriber for 403/404 or HttpExceptionSubscriberBase for general exceptions.

As example see this question for access denied: How can we catch the acces denied exception in drupal 8

The most important thing is to use a higher priority than the core event you want to override.