If you live in a poor country, it’s likely that being religious will give you a boost in your happiness. If you live in a wealthy country, it’s likely that your happiness will not be affected by religion, but if anything you may more depressed/sad if you are religious. Also of note (in retrospect quite obvious) is the fact that secular people in wealthy nations report being significantly more happy than religious people in impoverished nations.
Gallup polls asked respondents from each of the world’s 32 poorest countries and 31 richest countries “did you experience the following feelings during a lot of the day yesterday” and sorted responses into groups based on subjects religiosity to inquire whether happiness level correlates to religion.
On a related note “Gallup Polls in 143 countries reveal that among countries where average annual incomes are $2,000 or less, 92% of residents say religion is an important part of their daily lives. By contrast, among the richest countries surveyed — those where average annual incomes are $25,000 or more — that figure drops to 44%.”