It’s pretty easy to find good coffee in Barcelona, because Catalans (and Spanish people in general) love real coffee. That's why, although the city has all the usual franchises, you won't find many locals frequenting them. Neighborhoods like Gracia, el Born, and El Raval have the best coffee shops—mostly because the combination of workers and visiting travelers in those areas create a strong demand (especially during the breakfast time)—but even in the city center you can find a high-quality cup.
The most popular coffee drink here is a café solo (served in a small cup, like an espresso), or a cortado (a version of the macchiatto), but you can also order an American-style coffee everywhere.
My recommendations for coffee shops are below, but I'd also advise you to wake up early in the morning, buy a newspaper and enjoy your coffee with a good croissant at a nice outdoor terrace.
Located in Gracia, a beautiful neighborhood just 10 minutes from the city center, this is a very cool place to have a coffee after a nice lunch. Don’t go there in the morning, because they only open at midday; but after a walk to digest your lunch… or you can even have your lunch here because (in addition to the coffee) their food is excellent and attracts a very young clientele who seems to always be in a good mood. Enjoy the old-school vibe along with your café con leche.
I really love this place, which is just five minutes from the city center, and its traditional vibe. The owner is a former employee of The Ritz Barcelona who decided to pursue her dream of having her own little bar. The coffee is excellent, the pastries are splendid, and the place is also family-friendly, so if you are traveling with children, you won't find a better place to go with them.
A visit to this shop is an absolute must when you’re in Barcelona. Caelum sells pastries from all the convents in Spain (nuns are excellent bakers, you’ll see) and the peaceful atmosphere of the place is somehow related to that. This is the place to enjoy a good coffee and reward yourself with something sweet while reading a book. The location is also wonderful, in El Gotic, one of the nicest neighborhoods in the city.
Mesón del Café
The best thing about this place is not the coffee (in fact, the coffee isn't very good) but the bar, founded in 1909, which is so atmospheric that you’d pay to visit it. Their pastries are excellent (order a croissant and a hot chocolate), and you can come here at any time of the day, but the real reason to recommend this place is because the early 20th-century decór is rare to find in Barcelona.
Cafés el Magnífico
This tiny nook is simply the best place to have coffee in Barcelona. They supply coffee to a lot of bars in Barcelona, and now have their own bar, which serves the best coffee in town, by far. The smell and the taste of the coffee are really something special; and the café’s location in El Born means you’ll have lots of great streets to walk around after your coffee.