Unpredictable, technical exceptions, like NullPointerException or MethodNotFoundException. Such exceptions are the symptom of a bug in the software.
You can programatically navigate to an error page and explicitly add messages to be shown on the error page. This, however, is not the recommended way to show an error page. Instead you should throw one of the exceptions UnrecoverableException and RecoverableException. This is typically being done during the excecution of an JSF event handler. It can even be thrown from within EJBs or other beans that are managed by CDI.
There is a centralized exception handling available in AbstractManagedBean, FullAjaxExceptionHandler and PrimeExceptionHandler. That exception handling does the message display and error page navigation in a generalized way. The only thing you need to take care of is to decide, which exception type to throw and how to parameterize the exception object.
The error page location depends on the used template. That is taken care of in the overwritten versions of the exception handlers FullAjaxExceptionHandler and PrimeExceptionHandler.