# How to handle all errors?

**URL:** <https://www.ruby-forum.com/t/how-to-handle-all-errors/90778>\
**Category:** Rails\
**Created:** [April 1, 2007, 3:50pm UTC](https://www.ruby-forum.com/t/how-to-handle-all-errors/90778 "2007-04-01T15:50:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mix](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/919ad9/32.png) [@mix](https://www.ruby-forum.com/u/mix)\
**Post date:** [April 1, 2007, 3:50pm UTC](https://www.ruby-forum.com/t/how-to-handle-all-errors/90778/1 "2007-04-01T15:50:16Z")

</div>

Hi, is it possible to handle all errors? for example, now if someone try  
to go to an url that doesn’t exist a page “no action responded to …”  
is shown, is it possible to redirect to a default page?

---

<div class="post-metadata">

**Author:** ![mix](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/919ad9/32.png) [@mix](https://www.ruby-forum.com/u/mix)\
**Post date:** [April 1, 2007, 8:16pm UTC](https://www.ruby-forum.com/t/how-to-handle-all-errors/90778/2 "2007-04-01T20:16:17Z")

</div>

In production mode that would render your 404.rhtml page and your  
500.rhtml would be rendered on server errors. They should both be  
located in your public/ folder.

Fredrik

---

<div class="post-metadata">

**Author:** ![mix](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/919ad9/32.png) [@mix](https://www.ruby-forum.com/u/mix)\
**Post date:** [April 1, 2007, 9:27pm UTC](https://www.ruby-forum.com/t/how-to-handle-all-errors/90778/3 "2007-04-01T21:27:14Z")

</div>

Fredrik wrote:

> In production mode that would render your 404.rhtml page and your  
> 500.rhtml would be rendered on server errors. They should both be  
> located in your public/ folder.
> 
> Fredrik

ok, perfect 🙂  
thanks
