My wife and son have European passports but I don't. I have a residence card issued by Spain. Can I travel to the UK with my family without applying for a visa?
If it's an Article 10 or Article 20 card for family members of an EU/Schengen citizen, then you only need that and your passport.
Otherwise, you need an EEA Family Permit, a free visa.
It is clear that a residence card is not a passport. Your nationality defines whether you need a visa to enter the UK or not. You can check it here: https://www.gov.uk/check-uk-visa Your residence card issued by Spain gives you the right to apply for a UK visa (if you need one) from Spain.