get size of folders on root directory [duplicate]

My root directory "/" on my ubuntu server is filling up. I'd like to look at the folders in it and try to spot what's filling up. Can someone please tell me how to show the sizes of the folders in the root directory "/" (I think that's root, I always get confused with home "~")

Also is there a way to show the size of folders on a file system "/dev/nvme1n1p2"

code:

df -h /

output:

Filesystem      Size  Used Avail Use% Mounted on
/dev/nvme1n1p2  228G  213G  3.8G  99% /

Solution 1:

Yes! You could try du -chd1 /.

This will give you output similar to the following:

4.3G    /var
264M    /opt
...

Then to narrow down results you could replace / with any folder you'd like, such as du -chd1 /var

EDIT: I have edited the command with the suggestion from muru, and now this will include dot folders if scanning something like your home directory.