The standard guideline is 3-6 months of essential expenses — rent, groceries, EMIs, utilities, insurance premiums — not your entire lifestyle spending. If your income is irregular (freelance, business, commission-based), or you're the sole earner in your household, leaning toward 6-9 months is more prudent.
Where you keep it matters as much as how much you have. This money needs to be accessible within a day or two without any penalty or market risk, which rules out equity mutual funds, FDs with lock-ins, or anything you'd need to sell at a potential loss in a hurry.
A practical split many people use: keep 1-2 months of expenses in a regular savings account for instant access, and the rest in a liquid mutual fund or a sweep-in FD, both of which offer same-day or next-day access with modest but steady returns, meaningfully better than a savings account's interest rate.
Building this fund should typically come before aggressive investing, not alongside it — it's the foundation that lets you stay invested through a market downturn instead of being forced to sell at the worst possible time.