Merriam Webster defines resilience as "an ability to recover from or adjust easily to misfortune or change." In other words, it's being able to take a hit, deal with it, and move on.
Here are some ways to cultivate resilience so you can deal with the hits and keep going:
Acknowledge the hit. It can be tempting to pretend that nothing bad has happened, but that usually only works for so long. Facing reality and then making a rational decision on how to proceed is more likely to make you feel better.
Confide in someone you trust. Just having someone else validate your feelings can help you bounce back.
Have an attitude of gratitude. Although some things may be falling apart, odds are good you still have much you can be grateful for.
Take some time off. It can be an hour, a few hours, a day or even a few days. You could even decide to set a timer, allow yourself to feel bad during that time, and resolve to do something constructive after the timer goes off.
Treat yourself. As Gretchen Rubin says, "we must have treats." It can be as simple as a new book, a mani/pedi, or a hike - whatever makes you feel happier.
Make sure you take care of yourself. Get enough sleep, eat healthy foods, and exercise.
Change your perspective. Instead of viewing the difficulty as a setback, see it as an opportunity for growth. Ask yourself, "What can I learn from this?"
Keep the bigger picture in mind. If you believe in God, or a higher purpose, maybe you can have faith that things will work out. Spirituality and/or religion can be helpful in changing your perspective.
Look back on your accomplishments. Recall those times when you had to overcome adversity, and remember that you pulled through then, just as you will pull through now.