The simple rule is you should have one litter box per cat plus one more box in multiple locations around your home.
Even if a cat has unrestricted access to the outdoors, it’s a clever idea to supply a litter tray indoors just in case your cat doesn’t feel safe toileting outside or struggles to make it to the backyard fast enough because of old age or mobility problems.
You can never have enough litter boxes if you’re a cat, so let’s examine the proper number of litter trays per household including the Ins and Outs of the Litterbox.