In Spain, you'll find that most ATMs ("cajero automático" in Spanish, "caixer" in Catalan) have a withdrawing fee for international cards like Visa/Mastercard. ATMs are legally required to indicate the exact fee and ask for confirmation. So feel free to test around, cancel the transaction if the fee is too high for you and take some time to find the best ATM to use.
Fees can vary depending on:
Here are the ranges for each bank:
Read the comments for many updated ATM fees, and please let everybody know if you found a no-fees ATM or if you had different fees with your card.
If you are looking to send money to Spain consider using TransferWise for spending in any currency, receiving money for free and sending money internationally with low transparent fees — much cheaper than using your local bank. You can even get your own local bank account details in Europe, UK, US, Australia and New Zealand with the TransferWise borderless account.
Your own bank may also add its own fees. This is specific for each bank, so check with your bank pricing to see the fees for international withdrawals.
These ATMs have popped up everywhere in the center of touristic cities in Europe: do not use them. They have horrible fees and push users to withdraw high amounts of cash. Moreover the dynamic exchange rate (if you choose to let the ATM make the conversion for you, never do that) is outrageous.
Don't forget to ask for a receipt, especially when you're abroad. And once you have it, take a picture of it immediately because you'll probably end up losing the paper. Make sure the amount on the receipt matches the amount on your account. And in the case of a dispute, use your receipt/picture as a proof.