Cakey foundation is a problem for many people. It often comes down to your skin type, the type of foundation you use, and the steps you take before and after applying your foundation in terms of primers, moisturisers, application of the foundation, powders, setting sprays etc.
The first step to avoid your foundation caking or flaking is to determine what skin type you have. The easiest way to do this is by doing a tissue test. Take a tissue and make sure it is 1 ply, then push the tissue onto your skin and remove. If the tissue is completely dry, you probably have dry skin. If the tissue is slightly oily in the t-zone, then you likely have normal or combination skin. If the tissue is oily all over, you have oily skin.
The next step is to choose your foundation. Dewy liquid or cream foundations are best for dry skin types. Matte or dewy liquid foundations are best for normal and combination skin types, and matte liquid foundations are best for oily skin types.
Now that you've established your skin type and the foundation best suited for it, you can determine whether you need a primer, or a face oil or just simply moisturiser. There are many different primers on the market for specific skin types. If your skin is oily, be sure to use a magnifying primer. This will soak up any excess oil and stop your foundation from getting oily and possibly looking cakey. For dry skin types, your problem would probably be that your foundation looks flakey and sticks to the dry patches on your face. You can either use moisturising primers or use a facial oil that is fast absorbing and won't clog your pores, like rosehip or jojoba oil. For normal and combination skin types, a blurring primer or pore-filling primer works best to ensure an even, soft skin to apply your foundation onto.
The way in which you apply your foundation could also be causing your makeup to look cakey. If you prefer a full coverage, the best way to apply your foundation is thin layer by thin layer, rather than lots of product all at once. This will also result in you using less product, and your foundation will look smooth and flawless. The tools you use also hugely affect how your foundation looks. beauty blenders or sponges work exceptionally well. They mimic skin texture and absorb extra product, so that you're not applying heaps of foundation at once. Make sure your beauty blender is damp before you apply foundation - it expands when wet and applies foundation flawlessly. Some brushes leave streaks and applying your foundation with your fingers isn't the most hygienic, as it spreads germs and oil that are on your hands.
After you've applied your foundation, set it with powder. Most foundations need to be set with a translucent powder to avoid it transferring or fading throughout the day, as well as combating oiliness. Even if you have dry skin, a little bit of powder will help keep your makeup in place. If you have oily skin, you will need more powder, but again, layer the powder like you did your foundation, to avoid applying too much at once.
Once your makeup is set with powder and you've applied your blush, contour and highlighter, use a setting or fixing spray. setting sprays help keep your makeup in place and fixing sprays often just add a bit of dewiness to the makeup. However, both products are great for avoiding cakey foundation because they essentially melt the makeup together, set the powder, and avoid that powder or foundation from looking thick, dry or cracked.
It's crazy how many small changes to your makeup routine can make such a big difference. Primers and setting or fixing sprays can really improve the appearance of your makeup. If you've already got your skin type and foundation type down, then try adding or changing one or two things in your routine as mentioned above and maybe your makeup will become next level!