# stack level too deep

**URL:** <https://discuss.rubyonrails.org/t/stack-level-too-deep/1891>\
**Category:** rubyonrails-talk\
**Created:** [September 19, 2006, 11:07pm UTC](https://discuss.rubyonrails.org/t/stack-level-too-deep/1891 "2006-09-19T23:07:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Max\_Muermann](https://avatars.discourse-cdn.com/v4/letter/m/f4b2a3/32.png) [@Max\_Muermann](https://discuss.rubyonrails.org/u/Max_Muermann)\
**Post date:** [September 19, 2006, 11:07pm UTC](https://discuss.rubyonrails.org/t/stack-level-too-deep/1891/1 "2006-09-19T23:07:05Z")

</div>

It almost certainly means you have an (unintentional?) recursion in your code (a function that calls itself, which calls itself, etc...):

def recurse &nbsp;&nbsp;recurse recurse

Every time a function is called, a new frame is added on the stack. At some point, the Ruby interpreter decides that you have way too many stack frames and throws that error.

If you want to post the offending piece of code, we might be able to help with more specifics.

Max
