According to the International Monetary Fund (IMF) data for 2020, Germany had a GDP of approximately $3.8 trillion, making it the fourth-largest economy in the world. The UK had a GDP of around $2.6 trillion, ranking it as the sixth-largest economy globally.
So we are comparing 4th against 6th from 2020