Figuring out how many cabinets you should buy is a bit tricky, as every kitchen is different and so are household habits. To try and find the magic number for you, consider these points:
If you already own a few cabinets, run an inventory of everything that needs to be stored, which is also the right opportunity to get rid of clutter that you never use. Store everything neatly instead of cramming it in, and add enough cabinets for whatever is left out;
If you haven't got any cabinets at all, allowing two cupboards per adult and one for each kid is a great start;
Wanna get technical about it? Get your tape measure and calculator out! Consider the storage space that you need and buy cabinets that, combined, allow you to reach that range. When browsing models, you must multiply the cabinet's width for its depth and number of shelves or drawers:
For kitchens that are smaller than 150 ft², aim for 300" of wall cabinet storage space, around 880" of base models (including drawers), and a 180" pantry;
If your kitchen is between 150 and 350 ft², you could probably do with 360" of wall cabinets, 1015" of base cabinets, and a 230" pantry;
Is your kitchen bigger than that? We might be slightly jealous, but we can still tell you that you should easily fit over 360" of wall cabinets, around 1185" of base, and a large 310" pantry.
Of course, these aren't set rules, but they can help you figure out how many cabinets, combined, would allow you to achieve that recommended storage space.