Your question is far too general. Are you asking about bathroom or kitchen? What exactly are you trying to organize--cleaning, hair, or cosmetic products?? Please include a picture of the cabinet you are talking about with the doors open so we can see if there is a shelf, etc. You'll get much better help if you are very specific rather than general with your question.
Before you buy them, measure your space...including height.It all depends on what you are storing. With the dollar tree containers under the bathroom sink in our house, I keep folded cleaning rags, cleaning products, toilet paper, and kleenex. So simple to do inventory.Just customize them to your needs.
Get cubes that fit as closely as possible to your opening. If you don't have sliders, add felt or contact paper or some other medium to make sliding them easily.
Too general. Kitchen or bath. In the kitchen I took a 3/4" spring rod and put it up near the top of my under sink cabinets to hang spray bottles. Then had the grandkids and I measured across and up - 3" from the up number and 3" from the across number. According to my brilliant 8yr old granddaughter that gave me 1/2" between each of the buckets. She was right. Walmart has suction rods, we got 2 of the 12" skinny ones when we got the spring red. Those went on the top inside of the cabinet doors for gloves, dishtowels, etc.
The whole day cost us less than $30 including shelfpaper that was such a great sale we got enough for the rest of the kitchen, and 4 ice cream cones.