"IF" you are on city sewer you either have tree roots or other obstructions between your house and the main OR the main is backing up and you need to call the city before you have a major crisis. better make sure it is not 'your' house only having the problem first by checking with Roto- rooter or somebody that professionally cleans these things. Is there trees between your house and the main(anywhere), roots can run 50-100 feet easy.
IF it is septic, read previous post or address inadequate drain field. There is a deal now where you can have somebody 'approved' blow compressed air and styrofoam pellets into the drain field and make a old one work like new for half the price or so of digging and installing new and no muss or fuss.