Everything was going great and then, all of a sudden, your cat stopped using the litter box. Whether they started peeing/pooping in other corners or going right outside, there is always a reason why.
Could your cat have a medical problem? If you cat starts going outside of litter box for no apparent reason, take them to the vet. UTI and various kidney issues and kitty diabetes might be the culprit. Missing the litter box might be an early sign of a health problem that most of the time can be managed with medication and/or supplements.
Did you get a new cat? Are there enough litter boxes for all the cats in the house hold? Cat’s litter box needs change as they age. You may need to add a new box to your multi cat house hold.
Did you switch litter? Many cats need a gradual change in litter, and even then they might get uncomfortable.
Is your cat declawed? Many declawed cats are uncomfortable with various types of litter.
Is there an intruder outside of your window? A feral cat or a raccoon?
Here is a wonderful article on some reasons why your cat might be not utilizing the box as they were before