Onions are ready to harvest when the tops have fallen over. Let the soil dry out, harvest, and store in a warm, dry, dark place until the tops dry. Cut off the foliage down to an inch, then store in a cool, dry area. Garlic, on the other hand..
“While there’s no standard number of leaves that garlic should have, a reliable harvest indicator is when half the leaves have died off, and half are still green. The leaves start to die off from the bottom up. When most of your crop has reached this stage, stop watering for at least a week and allow the soil to dry out a bit to prevent rot and make harvesting easier.”