Were European Union laws legally binding in the UK?

Before Brexit, understanding the relationship between the UK and the European Union is key. The UK joined what was then called the European Economic Community in 1973. Over time, this evolved into the European Union, and membership meant accepting that EU laws had legal authority within the UK. This principle is rooted in the European Communities Act of 1972, which essentially made EU law part of UK law. So, any regulations or directives passed by the EU were directly enforceable in the UK courts and took precedence over conflicting national laws. This was a major point of contention for those who eventually voted for Brexit, as they felt it undermined the sovereignty of the UK Parliament. While it might seem like the UK could simply ignore EU laws, that wasn't the case; they were legally binding.
Before Brexit, the UK was subject to EU law.