When trading, follow a simple rule: Seek a bigger reward than the loss you risk.
This is called a risk-reward ratio. If you risk losing the same number of pips you hope to gain, then you risk-reward ratio is 1:1, meaning you set your stop and limit equidistant from your buy or sell price. If you take a 40-pip risk (stop) and target an 80-pip profit (limit), you have a 1:2 risk-reward ratio.
The higher the risk-reward ratio you choose, the less often you need to predict market direction correctly to make money. You should, however, use at least a 1:1 risk-reward ratio: If you are right only half the time, you break even.