# How do I find the size of a folder

**URL:** <https://www.ruby-forum.com/t/how-do-i-find-the-size-of-a-folder/127394>\
**Category:** Rails\
**Created:** [January 28, 2008, 9:48pm UTC](https://www.ruby-forum.com/t/how-do-i-find-the-size-of-a-folder/127394 "2008-01-28T21:48:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [January 28, 2008, 9:48pm UTC](https://www.ruby-forum.com/t/how-do-i-find-the-size-of-a-folder/127394/1 "2008-01-28T21:48:22Z")

</div>

Hi,

I am trying to work out the size of a folder using File.size(location  
of the folder), but this does not seem to return the correct size.

How can I find the size of a folder?

Kind regards,  
Dave.
