Why are solids and liquids ignored in the equilibrium constant? If a reaction is taking place and is going towards equilibrium, wouldn’t the reactant be consumed to form products and vice versa? If this reactant/product is a solid or liquid, wouldn’t the number of moles when the reaction reaches equilibrium decrease/increase from its initial number of moles? Wouldn’t this change in moles from start of reaction to point of equilibrium be important to the equation, since it’s a ratio of products to reactants at equilibrium?
A solid or liquid that should take part in a solution or gas phase reaction has to dissolve or evaporate before it can react in any meaningful way.

If you add more solid solute to a saturated solution, its concentration does not change, and so doesn't the equillibrium constant of a reaction of the dissolved solute.

(The solute might also react directly out of the solid. Theoretically. But this different reaction needs much more energy than the one from solution, and it will only add a minuscule shift to the total equillibrium, even if your solid has a huge surface. Surely neglectable, most likely not even measurable.)