With the rise of online retail markets, many online retailers are replicating the promotion strategies that offline retailers have used without a clear understanding of whether these strategies will deliver similar results in online markets. In particular, a loyalty program, which provides rewards that can be used for future purchase, is a widely adopted promotion strategy by both offline and online retailers with the intention of increasing customer retention and resultant profits. However, the profit contribution of loyalty programs in offline markets is highly controversial. Our question is whether the result will be similar in online markets. Our game-theoretic model shows that the likelihood of success for loyalty programs is higher in online than in offline markets. We note that consumers' preference for retail stores is more dynamic, and the cost of revisiting a store to redeem loyalty rewards is relatively lower in online markets, because consumers in online markets do not incur physical transportation costs. These characteristics provide the condition where loyalty programs effectively facilitate customer retention, while having fewer risks of rewarding the customers who would have made a purchase regardless of any offered rewards. Our model also suggests that, due to the more dynamic consumer preference in online markets, transaction data collected through loyalty programs provides stronger profit incentives for retailers. Our study helps retailers understand the differences between offline and online markets as well as the impact of the differences on the effectiveness of their loyalty programs.