A short history:
1976 - EEC Proposals 76/768/EEC to (1) ban animal testing of cosmetics in Europe, (2) animal testing of ingredients used solely in cosmetics in Europe, and (3) sale of cosmetics in Europe where animal testing was carried out elsewhere. These to be implemented when suitable non-animal testing was available.
1993 - 6th Amendment to 76/768/EEC proposes implementation in 1998.
1998 - UK alone implements all 3 parts of the ban. More amendments delay implementation in rest of Europe.
2004 - Rest of Europe bans (1) animal testing of cosmetics in Europe
2009 - Rest of Europe bans (2) animal testing of ingredients used solely in cosmetics in Europe.
2013 - Rest of Europe finally catches up with UK and bans (3) sale of cosmetics in Europe where animal testing was carried out elsewhere. 76/768/EEC is replaced with EU Regulation 1223/2009, but EU REACH rules determine that prohibitions do not apply to testing to determine if there is a risk to the environment (so called ‘ecotox testing’), or to worker safety tests.
This was the situation when UK left the EU and the EU rules were incorporated into UK law.
2020 - European Chemicals Agency (ECHA) Board of Appeal rules that even for sole use cosmetics ingredients, animal testing may be required for EU REACH.
For simplicity and time pressures, UK decides to follow the EU rules, so limited animal testing is again allowed for cosmetics and cosmetic only ingredients.
Late 2023 - UK expected to produce a new chemicals strategy as part of the much derided (especially by remoaners) review and revoke retained EU Law exercise. Due to Brexit, UK is allowed to tighten the rules, but is unlikely to loosen them as this would mean banning of UK exports to EU.