Imagine you live in a small town and you have two supermarkets.
The first one is across the street. You go there, you buy what you need, you pay for it, and you can leave with the products you've bought.
The second one is outside the city. You have to use your car to go to it, then you have to find a free parking spot (the parking being small, you have sometimes to wait for ten minutes or more for other customers to leave), then you have to travel by foot for five minutes, since the parking is not at the same place as the supermarket.
When entering in the supermarket, you have to register, which consists in providing lots of personal information about you, your bank account number, the age of your daughters, the list of things you're interested in, an address where advertisement will be sent (yes, it's mandatory), etc. Once registered, you wait for two days for your customer card to be ready, and then you can enter inside the supermarket.
Also, when paying for your products, they make a phone call to your bank to verify that your card is still valid. If they can't contact your bank, you have to wait until tomorrow.
Finally, each time you leave, you have to fill a questionnaire with your feedback about the supermarket. The questionnaire is ten pages long and all points are mandatory.
Which one of those markets do you choose?
The rule is: don't force the users to do things neither they, nor you need. If you provide a service to an end user, you must ensure the fastest possible access to this service (from UX point of view), with the fewest steps needed in order to use it:
If something can be done in one click of a mouse, don't force the person to do two clicks.
Don't force a person to fill 100+ fields in a form when you actually need only ten.
Don't force a person to spend two hours searching documentation when he needs to use a feature of your product he didn't use before.
Registration is a two way thing: when I register on Amazon, they have my e-mail account, and I can buy products on their website. Without registration, I can still see the products, but can't buy anything. When I register on Stack Exchange, I provide my identity to Stack Exchange, but in response, they provide me the ability to edit other people posts, comment, etc. As a guest, I can still see all the information and even post questions or answers. Through registration, I provide value to them, but I know perfectly well what I receive from them.
Forcing users to register just "because we can" is always bad. The users may want to ask two questions:
On Amazon or Stack Exchange, those questions are easy to answer. For example, on SE, I know precisely that it's a valuable, high-quality series of websites, plenty of competent and smart people, just by reading the questions and answers I have access to as a guest. On Amazon, I know precisely that once I register, I will be able to buy this specific product I'm looking on right now as a guest.
There is nothing worse as starting a relation with a potential customer by "register first, then we will show you how useful we are for you". Show your product. Let us touch it, test it, see if it really matches our expectations. Let us ensure you provide value competitors cannot provide.
Last but not least: many customers need to know why are you asking them to do something:
If I know that a website costs money to a person, and the only way to keep the website is to show ads to the users, I will be more inclined to not block those ads compared to a situation when I paid for a service a large amount of money, and I'm still forced to see the annoying ads.
If I know you need registration because your application cannot work without identifying the users or because it allows you to gather statistics for BI, improving the service in the future, I would register. If I have no idea why you're asking me to provide my e-mail address, the first idea that comes to mind is that you're just intending to spam me.