Melissa McCarthy shares the advice she wrote to herself many years ago

Melissa McCarthy sure knows how to give a pep talk.

After the hilarious "Bridesmaids" star uncovered a motivational letter she wrote to herself years ago, she decided to share it on Instagram — and now fans are forever grateful.

McCarthy shared an image of the handwritten note, which was addressed "To Me," on Monday.

The letter finds the Emmy winner creating a list of smart advice for herself about the most important aspects of life, including love, self-esteem, cookies and shoes.

"In 10 years you will not remember his name," McCarthy begins.

"It's OK to cry it out," she tells herself.

"For the love of God — buy both pairs of shoes," she urges.

Melissa McCarthy (Daniele Venturelli / WireImage)
Melissa McCarthy (Daniele Venturelli / WireImage)

The pearls of wisdom continue with McCarthy advising, "Please listen to that little voice inside your head" and, "A walk of shame can be character building."

"Call Mom" also makes the list along with, "Just eat the damn cookie!!"

McCarthy concludes her note by telling herself, "Go ALL IN — you'll never get today back."

The actor, who currently stars in the superhero comedy "Thunder Force" alongside real-life pal Octavia Spencer, captioned her post, "Found this note I wrote to myself years ago... still stands."

Fans responded in the comments by thanking McCarthy for the solid advice, with a few urging her to expand on the idea by writing a book.

"Please Write an inspirational book! Like a flip a day page book. Daily reminder kind of thing. ❤️ this!" wrote one.

The funny lady's famous friends also gave two thumbs up to her wisdom.

"Hear hear!!!" wrote "Beauty and the Beast" star Luke Evans.

"Yes!!" wrote former "Friends" star Courteney Cox, who added several hand-clapping emoji.

"Spot on," wrote actor Hilary Swank.

Related: McCarthy shared video of her emotional reaction to the Oscar-winning film.

Swank's admiration is hardly one-sided. In late April, McCarthy posted a video of herself sobbing after watching Swank's Oscar-winning turn as a waitress-turned-boxer in the 2004 drama "Million Dollar Baby."

"I just thought it was going to be a boxing movie and it wasn't," McCarthy says to the camera as she wipes away tears.

As for Swank's performance, McCarthy gushed, "Oh, my God, she was perfect."