This map shows how different countries around the world deal with the death penalty, and there are quite a few more countries that ban it outright than we thought. It's still legal and used in the U.S., though it is illegal in the majority of states in the U.S. You can tell it's a controversial topic when some countries are labeled as "illegal, with exceptions" or "legal, but not used."
If you were wondering, Brazil only allows the death penalty for crimes against humanity, terrorism, war crimes, and genocide. Israel has exceptions for similar crimes, though the country has ever only used the penalty once.