Lately, some friends have been asking for advice on choosing a university in Spain for a master’s or bachelor’s degree related to computer science. It’s a common question, as Spanish universities aren’t as widely known as those in the UK or the US, especially in STEM fields. Today, I’ll share some information I’ve gathered to get the conversation started, and I welcome everyone to join the discussion!
When it comes to rankings, they can be subjective but are always a useful reference. For computer science in Spain, the main international lists to check are the QS World University Rankings by Subject and the ShanghaiRanking’s Global Ranking of Academic Subjects. On these lists, a few universities consistently dominate, making them the powerhouses of Spain’s tech scene.

A Rundown of Top Computer Science Universities in Spain
The Two Tech Giants
If your goal is pure computer science or engineering, you almost can’t overlook these two institutions: the Polytechnic University of Catalonia (UPC) and the Polytechnic University of Madrid (UPM). In Spain, their reputation in engineering is on par with top-tier tech institutes globally. When considering the best Spanish universities for programming, UPC in Barcelona is particularly strong in computer science and artificial intelligence, while UPM in Madrid has deep-rooted expertise in software engineering and cybersecurity.
Besides these two, some comprehensive universities also offer excellent computer science programs. For instance, the University of Granada is a top choice in southern Spain for its AI and software engineering departments. To make comparison easier, I’ve created a simple table:
| University | City | Key Strengths |
| Polytechnic University of Catalonia (UPC) | Barcelona | Artificial Intelligence, Computer Graphics, High overall rankings |
| Polytechnic University of Madrid (UPM) | Madrid | Software Engineering, Cybersecurity, Strong industry connections |
| University of Granada | Granada | Artificial Intelligence, Computational Linguistics, Great value for money |
| Charles III University of Madrid (UC3M) | Madrid | Excellent teaching quality, Highly international, Small class sizes |
| University of Barcelona (UB) | Barcelona | Comprehensive university, Strong in theoretical research, Interdisciplinary advantages |
Choosing a school is a comprehensive decision. Beyond looking at universities in Spain for programming, you also need to consider factors like the city, cost of living, personal interests, and future career plans. For example, if you love the hustle and bustle of a big city and want access to internship opportunities, schools in Madrid and Barcelona are ideal. If you’re looking for great value and a more relaxed lifestyle, Granada is a hidden gem.
Are there any alumni from these schools here? Or students with application experience? Feel free to share your insights and experiences in the comments below to help out future applicants
! Don’t just lurk and leave!