The next time you fumble the facts when you’re reminiscing, psychologists have some comforting words: It doesn’t matter.

Inaccurate memories can even be good for you, according to several studies in the past year. They are often just as helpful as accurate memories in shaping people’s sense of identity and aiding goal-setting.

A middle-aged lawyer cherished a vivid boyhood memory of his father comforting him while his mother was in the hospital giving birth to a younger brother, says Martin Conway, head of the psychology department at City University London. The lawyer recalled his father distracting and entertaining him by talking about the landing of a man on the moon. He saw it as a sign that even with a baby brother on the way, his dad still loved and valued him, Dr. Conway says.

Only decades later did the attorney see that his recollection had to be wrong: His brother was born in 1968, a year before the first moon landing, says Dr. Conway, author of more than 150 studies on memory. “I’ve had this cherished memory for 30 years that I thought was true, but as I listened I suddenly realized it couldn’t be,” the attorney told Dr. Conway.

He had probably patched together details from separate events to form a single memory, Dr. Conway says. The memory was on-target in a deeper sense: “The fact that he was still loved was a truth to him, an important truth,” shoring up his sense of identity, Dr. Conway says. “It’s not so important that a memory be accurate. It’s more important that it helps us define ourselves.”

Illustration: Robert Neubecker

Dr. Conway’s work builds on a shift in psychologists’ understanding of long-term memories about our lives, or autobiographical memory. A growing number of researchers say memories are not just a storehouse for facts but also a creative blend of fact and fiction that helps people tell meaningful stories about their lives, set goals and envision the future in a realistic way.

It is commonly believed that storing a memory is like making a video, but long-term memories are never literal replays. They’re mental constructions of facts, inferences and imagined details that people patch together after the fact.

Sometimes, for instance, people infer details they didn’t notice or can’t recall, says a 2015 study by Dr. Conway and Catherine Loveday, a principal lecturer and neuropsychologist at the University of Westminster in London. In other cases, people compress long events into brief incidents or mistake events they imagined for real memories.

At times, that malleability makes memory vulnerable to manipulation. Numerous recent studies have shown how memory can be manipulated in ways that also can affect the accuracy of courtroom testimony. In order to explore the pitfalls of relying on the word of eyewitnesses in criminal trials, researchers have deliberately planted false memories in people’s minds. The researchers invited subjects to imagine themselves having an experience in the past, such as getting in trouble as a child for calling 911 or winning a stuffed animal at a carnival.

How Memories Become Distorted We imagine that something happens and mistake it for an actual past event

We confuse and combine memories of two different events

We compress events that happened over long periods into a very short time

We exaggerate positive or negative details for dramatic effect

We alter our memories to conform with others’ beliefs or views

We change our memories to reflect updated information

However, the same capacities that cause us to rewrite or make up memories can be useful, enabling us to imagine the future and make creative associations among unrelated facts. Remembering past events and imagining possible future happenings engage the same regions of the brain, according to a 2011 study led by Daniel Schacter, a psychology professor at Harvard University.

People sometimes fictionalize memories to protect themselves from recalling experiences that threaten their beliefs about themselves. College students who opposed a tuition increase but wrote persuasive essays supporting the idea as part of an experiment later misremembered their initial attitudes. They said they’d supported the increase all along, according to a 2015 study of 120 students led by Dario Rodriguez, a lecturer in psychology at the University of Dayton in Ohio.

Others omit inconvenient details when recalling past experiences so they can tell more coherent or hopeful stories, says Dan McAdams, a psychology professor and researcher at Northwestern University and author of two books on personality development. “Maybe six things happened during a particular event, and the third one is really toxic,” he says. After concluding “nothing good could come of it, you just conveniently forget that third part.”

Many people exaggerate the darkness or misery of past experiences, so their “escape from there becomes even more impressive,” Dr. McAdams says. This enables the storyteller to strike a redemptive note: “I wouldn’t be the strong person I am today if I hadn’t gone through that.”

People also interpret past events in completely new ways as they move from one life stage to the next, says Robyn Fivush, a psychology professor at Emory University in Atlanta.

Matthew Graci, 27, remembers feeling bad about himself years ago when his high-school guidance counselor and other adults reproached him for failing to get grades that matched his potential. He acknowledges that he didn’t study much. “I was voted class clown in high school, and that was a major part of my identity.”

A turning point came at age 18, when Mr. Graci surprised himself by making the dean’s list during his first semester in college, he says. He looked back at his lackluster performance in high school and reinterpreted it as a sign of boredom. He also recalled other ways he’d challenged himself, such as by reading scholarly books on his own. “Now, there’s a redemptive arc to my story, and I’m on the upswing,” says Mr. Graci, a doctoral candidate in psychology at Emory University.

Memories tend to stick with us when they happen during a time of rapid growth and development. Teens, for example, tend to recall memories that help them figure out their identity and role in society.

More Work & Family columns Work & Family Mailbox: Sue Shellenbarger Answers Readers’ Questions

Liz Guidone, 27, vividly recalls an emotional memory from 17 years ago when she challenged some bullies, older members of a choir she had joined. The girls were taunting Ms. Guidone’s African-American friend, and she reported it to the choir director after finding her friend crying in the restroom. The older members turned on Ms. Guidone, who is white, and accused her of lying, leaving her doubting her decision to speak up.

After her father arrived to drive her home, “he stopped me in the parking lot, looked me in the eyes and told me he was proud of me for speaking up, even though it didn’t make me popular,” says Ms. Guidone, of New Haven, Conn. The memory of her father’s support taught her to trust her judgment in telling right from wrong, and it has helped shore up her self-confidence in difficult times, Ms. Guidone says.

Your choice of people to tell about past memories helps determine whether you remember them accurately—or at all. Sharing stories with listeners who pay attention and are emotionally responsive aids in recall of facts and helps storytellers find meaning in past experiences, according to research by Monisha Pasupathi, a professor of developmental psychology at the University of Utah, Salt Lake City, and others. Sad experiences in particular tend to take on more meaning when recounted to others.

Never try to tell memories to a listener who is obviously distracted. Dr. Pasupathi’s research shows that an uninterested response not only defeats storytellers’ efforts to find meaning but also increases the likelihood that they’ll forget the experiences altogether.