When we say that someone is lucky, we tend to think that their success or failure is brought by chance rather than through their personal actions, but luck is actually more psychological than it is anything else. It’s related to how we view the world, our personality and how our brain is wired.

Our brain is wired to look for patterns, and that wiring is how we have survived. Like Pavlov’s dogs who salivated when the bell rang because they knew food was coming, our mouths water and stomachs grumble when we see a ripe fruit or a perfect cupcake. Our brain is looking for the magic combination that will make us feel good. The feel-good neurotransmitter, dopamine, is a big part of this. When we feel like we have lucked out or lucked into something, we feel good. When we feel good, dopamine floods the reward centers of the brain and the emotion and memory regions of the brain. Our brain dedicates a lot of time and energy to pattern recognition. So, if we wear lucky socks and make an A on an exam that day, it reinforces our belief system—it was luck!—and our connections get stronger.

Many believe luck is tied to superstition. For example, we knock on wood to prevent bad luck from affecting us after making a bold or confident statement. To help our team win, we may carry a lucky rabbit’s foot or wear a lucky shirt to a sporting event; the athletes competing may have a lucky pregame ritual. And these superstitions can work, but not in the way we think they do. In one study, participants performed better in solving an anagram problem because they were allowed to hold their “lucky charm.”

Researchers hypothesized that the people with the lucky charms persisted at the problems longer because they felt more effective—like they had the assistance of something outside of themselves. People feel empowered when they think that someone, or something, is helping them so they actually do better at the task at hand. Lucky talismans—any object that someone believes holds magical properties to bring good luck and protection—remind their owners to be courageous in adverse situations. But they are symbolic more than anything else.

One personality factor that stands out as consistently correlated with luck is extraversion. Extraverts are more open to opportunities, more connected to a large network of people, more likely to mix up their routines, and more likely to have an easygoing attitude toward life. Extraverts smile twice as often and engage in more eye contact. Sociability helps to increase the likelihood of a lucky opportunity because they meet more people, connect better, and maintain relationships.

Even for those of us who are not extraverts or who may not feel lucky, there’s hope because we have the power to make our own luck. We can be more optimistic and open to new experiences. When you reflect on your day and week, put more emphasis on the good than the bad. Instead of complaining when something less-than-desirable happens, like a scraped knee or stubbed toe, be grateful that it’s not worse. People who feel they are unlucky are more likely to dwell on setbacks and see the glass as half-empty during difficult times. These people are more likely to count on things going wrong, so they give up sooner.

Here are some things you can do to increase your luck.

Keep an open mind and be observant. Having an open attitude and looking around for new opportunities can open you up to lucky chances. Worrying too much about something or focusing singularly on one goal can close you off to other possibilities. Open yourself up to new places; you never know what you might find.

Look on the positive side. Focus on practicing optimism and gratitude. Harping on what’s negative dampens your spirits and future expectations. Don’t focus on the downside of the flat tire, but the upside of your full-coverage insurance and the new coffee shop you found while waiting for a fix. When that happens, it becomes easier to try new things. Positive expectations lead to self-fulfilling prophecies.

Step out of your routine. Do something out of the ordinary this week. Routines can lead to ruts, whether it’s talking to the same people, eating the same food or doing the same type of work. Stepping outside your boundary increases the likelihood of a lucky break.

Some people are born with advantages, some people are naturally outgoing or optimistic, and some events happen to us that are outside our control. But we can always do something to build on what we do have. It starts with having a “lucky” attitude toward life.